-
Notifications
You must be signed in to change notification settings - Fork 472
Add the referential_constraints view to information schema #2637
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
+cc @knz |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for tackling this.
Mostly good, except for a bug in views
.
paging @nvanbenschoten for additional control
v2.0/information-schema.md
Outdated
@@ -168,8 +189,8 @@ The `views` view identifies [views](views.html) in the cluster. | |||
|
|||
Column | Description | |||
-------|----------- | |||
`TABLE_CATALOG` | Always equal to `def` (CockroachDB does not support the notion of catalogs). | |||
`TABLE_SCHEMA` | Name of the database that the view reads from. | |||
`TABLE_CATALOG` | Name of the database that the view reads from. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both the original doc text and the new one are incorrect. the table_xxx
columns in this table refer to the view itself, not the table(s) being read from. A view can read from multiple tables.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.
Could somebody tell me what the CI failure here means / what I should do to correct it? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks, @spencerkimball!
Update all information schema tables to match implementations, including updating the meanings of `_CATALOG` and `_SCHEMA` columns. From my review, other incomplete items in information_schema that require fixes: - CHARACTER_SET_* and GENERATION_EXPRESSION in `columns` table. - administrable_role_authorizations - applicable_roles - column_privileges - enabled_roles - role_table_grants - sequences - `statistics` table needs `IMPLICIT` defined. See cockroachdb#2017 Fixes cockroachdb#2508
Update all information schema tables to match implementations, including
updating the meanings of
_CATALOG
and_SCHEMA
columns.From my review, other incomplete items in information_schema that
require fixes:
columns
table.statistics
table needsIMPLICIT
defined.See #2017
Fixes #2508