Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dataset XML
Message
 
À
20/11/2004 11:38:15
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
Versions des environnements
Environment:
C# 1.1
OS:
Windows XP
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
00963184
Message ID:
00963249
Vues:
7
Bonnie,

I have code like this:

SqlCommand cmd;
cmd=new SqlCommand("select PK_ADR, navn, fk_postnr from m0_Adressat WHERE (pk_ADR =109271 )");
cmd.Connection=this.sqlConnection1;
// cmd.ExecuteReader();
this.sqlDataAdapter1.SelectCommand=cmd;
this.dsAdrData=new DataSet("dsAdr");
this.sqlDataAdapter1.Fill(this.dsAdrData,"M0_Adressat");
cmd=new SqlCommand("Select PK_JOURNALID, aar, jrnlnr, fk_adr, regdato from m1_Journal where (fk_adr=109271)");
cmd.Connection=this.sqlConnection1;
this.sqlDataAdapter1.SelectCommand=cmd;
this.sqlDataAdapter1.Fill(this.dsAdrData,"M1_Journal");
return this.dsAdrData.GetXml()

but this is not using the schema description I have in a xsd-file. How do I connect data with the schema? (I thought I should end up with a nested dataset)


>Einar,
>
>First off, so nobody tries to re-invent the wheel ... what have you got done so far? It sounds like you've accomplished your task when your DataSet has just one table. Could you please post some code and then maybe we can point you in the right direction ....
>
>~~Bonnie
>
>
>>Can you help me with a sample for the following?:
>>
>>I have created a dataset in a xsd-file as a customer table with several related tables (Like master-detail-detail). I want to select a single customer with related data using sqlAdapter and fill the dataset which then is to be stored as xml in a memo-field on another server. I have not figured out how to do this when there are more than one table involved.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform