DictTable.indexUnique Method
Returns the ID of the unique index for the table.
Syntax
public IndexId indexUnique()
Run On
Called
Return Value
Type: IndexId Extended Data Type
The ID of the unique index for the table.
Remarks
When there is more than one unique index on the table, the return value is one of the following:
The index that has the RecID column.
If no index has a record ID, the index that has the shortest size, based on the total size of columns.
If multiple indexes match with regard to the shortest size, the index that was added first.
Examples
The following example shows the retrieval of the unique index for a table.
DictTable dt;
DictIndex di;
dt = new DictTable(tablenum(SysUserInfo));
if (dt)
{
di = dt.indexObject(dt.indexUnique());
if (di)
{
print di.name();
}
}