JDBC Driver for Google BigQuery

Build 22.0.8462

sys_keycolumns

Describes the primary and foreign keys.

The following query retrieves the primary key for the [publicdata].[samples].github_nested table:

         SELECT * FROM sys_keycolumns WHERE IsKey='True' AND TableName='github_nested' AND CatalogName='publicdata' AND SchemaName='samples'
          

Columns

Name Type Description
CatalogName String The name of the database containing the key.
SchemaName String The name of the schema containing the key.
TableName String The name of the table containing the key.
ColumnName String The name of the key column.
IsKey Boolean Whether the column is a primary key in the table referenced in the TableName field.
IsForeignKey Boolean Whether the column is a foreign key referenced in the TableName field.
PrimaryKeyName String The name of the primary key.
ForeignKeyName String The name of the foreign key.
ReferencedCatalogName String The database containing the primary key.
ReferencedSchemaName String The schema containing the primary key.
ReferencedTableName String The table containing the primary key.
ReferencedColumnName String The column name of the primary key.

Copyright (c) 2023 CData Software, Inc. - All rights reserved.
Build 22.0.8462