Skip to content

Latest commit

 

History

History
44 lines (34 loc) · 1.93 KB

modify-method-xml-data-type.md

File metadata and controls

44 lines (34 loc) · 1.93 KB
title description author ms.author ms.date ms.service ms.subservice ms.topic helpviewer_keywords dev_langs
modify() Method (xml Data Type)
modify() Method (xml Data Type)
MikeRayMSFT
mikeray
07/26/2017
sql
t-sql
reference
modify() method
modify method
TSQL

modify() Method (xml Data Type)

[!INCLUDE SQL Server Azure SQL Database Azure SQL Managed Instance]

Modifies the contents of an XML document. Use this method to modify the content of an xml type variable or column. This method takes an XML DML statement to insert, update, or delete nodes from XML data. The modify() method of the xml data type can only be used in the SET clause of an UPDATE statement.

Syntax

modify (XML_DML)  

[!INCLUDEsql-server-tsql-previous-offline-documentation]

Arguments

XML_DML
Is a string in XML Data Manipulation Language (DML). The XML document is updated according to this expression.

Note

An error is returned if the modify() method is called on a null value or results in a null value.

Examples

Because the modify() method requires a string in the XML Data Manipulation Language (DML), the samples for modify() are contained in the topics that describe the XML DML statements. For these examples, see insert (XML DML), delete (XML DML) and replace value of (XML DML).

See Also

Create Instances of XML Data
xml Data Type Methods
XML Data Modification Language (XML DML)