Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Converting XML in Stored Procedure to temp table
Message
 
General information
Forum:
Microsoft SQL Server
Category:
Other
Environment versions
SQL Server:
SQL Server 2005
Miscellaneous
Thread ID:
01543487
Message ID:
01543498
Views:
38
>Hi,
>
>I am "translating" my VFP stored procedure into a SQL Server stored procedure. The VFP stored procedure receives a couple of small XML files (as strings) and then "deals" with them. How do I convert an XML string file inside SQL Server stored procedure into a temp table? I think that once I have the XML in the temp file I can go on with processing it. Or if you have any other suggestion on how to make an XML string inside SQL Stored procedure as a series of variables, please let me know.
>
>TIA.

So far the examples I see online for selecting values from an XML are different from my "version" of XML. Here is an example of what my XML look like:
<TABLENAME>
   <Fld Name="Field1">ValueInField1</Fld>
   <Fld Name="Field2">ValueInField2</Fld>
   <Fld Name="Field3">ValueInField3</Fld>
</TABLENAME>
Anybody knows the t-sql syntax to parse this type of XML? That is, how to get values?

Thank you.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform