-
Notifications
You must be signed in to change notification settings - Fork 710
Add docs for the I_S keyword table #15795
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
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
7e064a3
Add docs for keyword table
dveeden 7fab91b
Fix lint issue
dveeden 3748bb3
Add to TOC
dveeden f0e1ea4
Small corrections
dveeden 469b137
Update information-schema/information-schema-keywords.md
dveeden 97243e8
Update information-schema/information-schema-keywords.md
dveeden 91850a2
Update keywords.md
dveeden eb57f4c
Update information-schema/information-schema-keywords.md
dveeden 9ff86fd
Update information-schema/information-schema-keywords.md
dveeden 8b5a2db
Update information-schema/information-schema-keywords.md
dveeden 7053a97
Apply suggestions from code review
Oreoxmt ff9ad8d
Apply suggestions from code review
dveeden f6684cd
make ci happy
Oreoxmt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,48 @@ | ||
| --- | ||
| title: KEYWORDS | ||
| summary: Learn the `KEYWORDS` INFORMATION_SCHEMA table. | ||
| --- | ||
|
|
||
| # KEYWORDS | ||
|
|
||
| Starting from v7.6.0, TiDB provides the `KEYWORDS` table. You can use this table to get information about [keywords](/keywords.md) in TiDB. | ||
|
|
||
| ```sql | ||
| USE INFORMATION_SCHEMA; | ||
| DESC keywords; | ||
| ``` | ||
|
|
||
| The output is as follows: | ||
|
|
||
| ``` | ||
| +----------+--------------+------+------+---------+-------+ | ||
| | Field | Type | Null | Key | Default | Extra | | ||
| +----------+--------------+------+------+---------+-------+ | ||
| | WORD | varchar(128) | YES | | NULL | | | ||
| | RESERVED | int(11) | YES | | NULL | | | ||
| +----------+--------------+------+------+---------+-------+ | ||
| 2 rows in set (0.00 sec) | ||
| ``` | ||
|
|
||
|
dveeden marked this conversation as resolved.
|
||
| Field description: | ||
|
Oreoxmt marked this conversation as resolved.
|
||
|
|
||
| - `WORD`: The keyword. | ||
| - `RESERVED`: Whether the keyword is reserved. | ||
|
|
||
| The following statement queries the information about `ADD` and `USER` keywords: | ||
|
|
||
| ```sql | ||
| SELECT * FROM INFORMATION_SCHEMA.KEYWORDS WHERE WORD IN ('ADD','USER'); | ||
| ``` | ||
|
|
||
|
dveeden marked this conversation as resolved.
|
||
| From the output, you can see that `ADD` is a reserved keyword and `USER` is a non-reserved keyword. | ||
|
|
||
| ``` | ||
| +------+----------+ | ||
| | WORD | RESERVED | | ||
| +------+----------+ | ||
| | ADD | 1 | | ||
| | USER | 0 | | ||
| +------+----------+ | ||
| 2 rows in set (0.00 sec) | ||
| ``` | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.