*: support invisible database / table #14069
Closed
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.
What problem does this PR solve?
Support the invisible database/table. e.g.
This visible database/table is the normal database/table. This invisible database/table is invisible which means this database/table only can be changed the database/table schema. We only can do
alter database/table
anddrop database/table
operation on invisible database/table. In order to know the structure of the invisible database/table, theshow create database/table
operation is supported on the invisible table.Relate to pingcap/parser#674
It's used for pingcap/br/issues/87.
What is changed and how it works?
create database/table ... invisible
creates a database/table with the state ofdelete-only
.alter database/table ... visible
changes a database/table topublic
.Check List
Tests
Unit tests need to be added.