Assume this is your XML snippet

SET @authorsXML = '
    <Street>10932 Bigge Rd.</Street>
    <City>Menlo Park</City>

Note that the examples below show how you can manipulate XML nodes – but most operations require singleton values. Ie, the changes must affect one and only one node. Thus in most the examples we specify the index of the node we want to target.

For example:


which means we are only targetting the first instance of LastName under the Author node. If you need to do a mass update, you may need to use a cursor.

Read the rest of this entry »

VN:F [1.9.22_1171]
Rating: 9.5/10 (46 votes cast)
VN:F [1.9.22_1171]
Rating: +11 (from 11 votes)