Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 XML Output to Local Drive
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

1 Posts

Posted - 09/05/2013 :  14:04:19  Show Profile  Reply with Quote
Hi All,

We have created a stored procedure in sql server 2008 which returns the output results in XML. I need to store this XML in my local drive.

I have tried using SSIS but it gives me an error "Error in rool level element" Even though i have proper parent element.

Please let me know how can i achieve this requirement.


Starting Member

United Kingdom
10 Posts

Posted - 09/09/2013 :  09:48:41  Show Profile  Reply with Quote
Hi Sahu,

Could you provide an example of the xml you are attempting to write to a file?

*# Nothing is truly idiot proof, because the world keeps producing a higher class of idiot #*
Go to Top of Page

James K
Flowing Fount of Yak Knowledge

3873 Posts

Posted - 09/09/2013 :  10:23:10  Show Profile  Reply with Quote
Couple of additional thoughts:

1. SQL XML accepts even XML fragments; i.e., there does not need to be a root element for SQL to process it. Since you have indicated that you have "proper parent element", I am assuming that you have a root element.

2. Simplify your problem to a very simple XML document, perhaps with a root node and one element under it and see if you can process that through SSIS successfully.

3. If neither of the above helps, as Cooper suggested, post a representative sample of your XML.
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.02 seconds. Powered By: Snitz Forums 2000