Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Please help with getting the right structure from dataset using GetXML()

From: Martin Honnen <mahotrash@-----.-->
To: NULL
Date: 3/9/2009 7:13:00 PM
emailhelen@g... wrote:

> I am in fact using SQL Server 2005. I would love to know how to handle
> this best through the SQL server. If you think XSLT would be a better
> option I would love to hear about that as well. I am afraid I am quite
> a newbie when it comes to this. Thanks again for your anticipated
> assistance!

With MS SQL Server you can use the FOR XML clause in SELECT statements 
to generate XML directly. With SQL Server 2005 you have the powerful FOR 
XML PATH, see your local SQL Server documentation or this section on MSDN:
http://msdn.microsoft.com/en-us/library/ms189885(SQL.90).aspx

If you need help then post your table structures, some sample data and 
the XML you want to generate from that sample data, then we can try to 
help you with the FOR XML PATH. You might however better do that in 
microsoft.public.sqlserver.xml as it is more likely that someone with 
skills in T-SQL and FOR XML reads that than here.

-- 

	Martin Honnen --- MVP XML
	http://JavaScript.FAQTs.com/


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent