SQL2000Determineprimarykeyfromsystemtable lists all PrimaryKeySELECTobject_name (. [id]) as [TableName], object_name (. constid) as [PK_name], B. [name] as [PK_Column] FROMsysconstraintsainnerjoinsyscolumnsbona. [colid] + 1b. [c
SQL 2000 Determine primary key from system table lists all Primary Key SELECT object_name (. [id]) as [TableName], object_name (. constid) as [PK_name], B. [name] as [PK_Column] FROM sysconstraints a inner join syscolumns B on. [colid] + 1 = B. [c
SQL 2000 Determine primary key from system table list all Primary keys
SELECT object_name (a. [id]) as [TableName]
, Object_name (a. constid) as [PK_name]
, B. [name] as [PK_Column]
FROM sysconstraints a inner join syscolumns B
On a. [colid] + 1 = B. [colid] and a. [id] = B. [id]
WHERE a. status = 2593
PS. Status = 2593 file description not found for confirmation, and overwriting Key may not apply