| Database Toolbox | ![]() |
Get database table unique row identifier
Syntax
Description
b = bestrowid(dbmeta, 'cata', 'sch')
determines and returns the optimal set of columns in a table that uniquely identifies a row, in the schema sch, of the catalog cata, for the database whose database metadata object is dbmeta, where dbmeta was created using dmd.
b = bestrowid(dbmeta, 'cata', 'sch', 'tab')
determines and returns the optimal set of columns that uniquely identifies a row in table tab, in the schema sch, of the catalog cata, for the database whose database metadata object is dbmeta, where dbmeta was created using dmd.
Examples
dbmeta is the database metadata object.
msdb is the catalog cata.
geck is the schema sch.
builds is the table tab.
The results is build_id, which means that every entry in the build_id column is unique and can be used to identify the row.
See Also
columns, dmd, get, tables
| attr | clearwarnings | ![]() |