Primary Property

The Primary property indicates whether the given index is a primary key.

Applies to objects: Index.

Syntax

[[Let] RetVal = ] object.Primary

[Let] object.Primary = SetVal

The Primary property syntax has these parts:

Part Description
object Required. A reference to an instance of the object.
RetVal Optional. A Boolean type variable.
SetVal Required. A Boolean type variable.

Remarks

This property can only be defined when index is created. Otherwise modifying this property is ignored.

A table may have only one primary key.

Example

.......

 

See Also

Index Object, TableDef Object, Unique Property.