By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,946 Members | 734 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,946 IT Pros & Developers. It's quick & easy.


P: 6
I am using VB.NET script in my SSIS package to create an XML file. Here is an outline of what I have done.

I have a select statement that gives me records as follows.

CustomerID PersonID Employment PhoneNumber IsFulltime
1 34 Township 343434343 1
2 34 Construction 343422234 0
3 35 Township 3434234 1
4 39 Township 34321111 1
5 39 Township 22222222 1

The data is such that one customer can have one job or more and one job can have one phone number or more. My XML structure is as below.

<Person> 34 </Person>
<Employment> Township </Employment>
<Employment> Construction </Employment>
<phone> 3434343 </phone>
<phone> 343422234</Phone>

i have used simple .net script to do so using xml writer. I use if statements and while loops to determine if the employment is more than one or if phone number is more than one. This I feel is not the most optimal way of doing so. I am basically a database developer working with and xml for the first time. I was researching xml schema on the web and trying to find out if I could make a schema first and then get my desired output without making extended if statements and while loops. Does anyone have a better solution?
Apr 22 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.