Skip to content

Core

Version 5.7.0

Added

  • Clustered indexes. TableIndex.Clustered, PrimaryKey.Clustered and UniqueConstraint.Clustered record whether a relation’s rows are physically ordered by that index, written as T-SQL writes it.
  • A relation may declare only one clustered index. multiple-clustered-indexes is an error: a clustered index is the relation’s row order, so a second one has nothing left to order.
  • Clustering an engine cannot honor is reported rather than dropped. SqlDialect.SupportsClustering says whether the engine has clustered indexes at all.
  • XML schema collections. Schema.XmlSchemaCollections holds the named XSD bundles a typed xml column is validated against, written as CREATE XML SCHEMA COLLECTION s.name AS '…' and bound from a column as xml(DOCUMENT s.name).
  • XML indexes. TableIndex.Xml carries an XmlIndexDefinition — the kind (primary, path, value, property) and, for a secondary, the primary XML index whose node table it reads. Written as SQL Server writes it.
  • Views declare their schema binding. View.IsSchemaBound records whether a view is bound to the schema of what it reads, written in NSQL as CREATE VIEW name WITH SCHEMABINDING AS …, the spelling SQL Server uses.

Changed

  • An unscoped run stays unscoped. It no longer derives a schema list from the project and the recorded state. What a run may touch is the managed set’s job.
  • A view may carry indexes whether or not it is materialized. CREATE INDEX … ON schema.view no longer requires the view to be materialized.
  • CreateIndex says whether its owner is a view. The new OnView flag rides the action, as IsMaterialized does on the view actions.

Fixed

  • Objects managed inside an unmanaged schema are no longer stranded. An object can be managed in a schema that is not.
  • A comment opening an opaque body survives the round trip. A view body or routine definition whose first line is a comment lost it on re-parse. This is now fixed.
  • A view carrying indexes is recreated, not replaced. Indexes hang off a view’s stored form, and SQL Server’s CREATE OR ALTER VIEW drops an indexed view’s indexes outright, so redeclaring one in place destroyed them silently. A body or binding change on a view carrying indexes now drops and recreates it, rebuilding the indexes with the definition.