Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
Using Nodes() Method in Sql Server
Amit Singh
Sep 22 2016 12:58 PM
223
Reply
DECLARE @xmlDataHandle INT
EXEC Sp_xml_preparedocument
@xmlDataHandle output,
@XmlSourceData
UPDATE source
SET status = Cast(_xmlPayment.xmlstatus AS BIT)
FROM OPENXML(@xmlDataHandle, '/Sources/Source', 2)
WITH( xmlstatus BIT '@status',
xmlid VARCHAR(50) '@id' )_xmlPayment
WHERE source.sourceid = Cast(_xmlPayment.xmlid AS INT)
EXEC Sp_xml_removedocument
@xmlDataHandle
SELECT '1'
Convert this query using Nodes() Method of Sql Server instead of Openxml
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
To migrate sqlserver 2005 To 2016
Syntax to create store proc with transaction commit and roll