>[PRIMARY] XML > > Creates an XML index on the specified xml column. When PRIMARY is specified, a clustered >index is created with the clustered key formed from the clustering key of the user table and an >XML node identifier. Each table can have up to 249 XML indexes. Note the following when you >create an XML index: > > * A clustered index must exist on the primary key of the user table. > * The clustering key of the user table is limited to 15 columns. > * Each xml column in a table can have one primary XML index and multiple secondary XML > indexes. > * A primary XML index on an xml column must exist before a secondary XML index can be > created on the column. > * An XML index can only be created on a single xml column. You cannot create an XML index > on a non-xml column, nor can you create a relational index on an xml column. > * You cannot create an XML index, either primary or secondary, on an xml column in a > view, on a table-valued variable with xml columns, or xml type variables. > * You cannot create a primary XML index on a computed xml column. > * The SET option settings must be the same as those required for indexed views and > computed column indexes. Specifically, the option ARITHABORT must be set to ON when an > XML index is created and when inserting, deleting, or updating values in the xml > column. For more information, see SET Options That Affect Results. > > For more information, see Indexes on xml Data Type Columns. >