User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the VB.NET section within the Software Development category of DaniWeb, a massive community of 456,598 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,453 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our VB.NET advertiser: Programming Forums
Views: 869 | Replies: 0
Reply
Join Date: Sep 2007
Posts: 3
Reputation: stevestare is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
stevestare stevestare is offline Offline
Newbie Poster

vb.net + sql 2000 + xml file

  #1  
Sep 7th, 2007
I’m selecting data from tables in a SQL Server 2000 data base, and putting the result into a Dataset.

I’m writing the dataset out to a file in XML format using ds.WriteXml(myXmlWriter, XmlWriteMode.IgnoreSchema).



The table names are in singular (i.e. table customer is called “customer”), if I have more than one record in the table, I need to preceed my table name with a plural name (i.e. “customers”) in the instance of my XML file.



Example:

</customers>

</customer>SMITH</customer>

</customer>/JONES</customer>

<customers/>



This is my first time working w/XML file. Please advise me how to do the following:

How do I manipulate a dataset to insert a tag or node containing the plural table name (i.e. customers) if there is more than one record in the table?
Some of the columns contain NULL values, when my dataset is built, SQL Server 2000 omits the columns that have the value NULL, I need to include the null columns and have the ending node tag to write xsi:= nil.


Thanks for your help
AddThis Social Bookmark Button
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb VB.NET Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the VB.NET Forum

All times are GMT -4. The time now is 7:00 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC