feat: show databases and show tables (#276)

* feat: ensure time index column can't be included in primary key

* feat: sql parser supports show tables statement

* feat: impl show databases and show tables, #183

* feat: impl like expression for show databases/tables and add tests

* fix: typo

* fix: address CR problems
This commit is contained in:
dennis zhuang
2022-09-26 14:05:49 +08:00
committed by GitHub
parent 5f322ba16e
commit 0fa68ab7a5
14 changed files with 681 additions and 96 deletions

View File

@@ -45,11 +45,12 @@ where
/// Converts statement to logical plan using datafusion planner
fn statement_to_plan(&self, statement: Statement) -> Result<LogicalPlan> {
match statement {
Statement::ShowDatabases(_) => {
todo!("Currently not supported")
}
Statement::Query(qb) => self.query_to_plan(qb),
Statement::Create(_) | Statement::Alter(_) | Statement::Insert(_) => unreachable!(),
Statement::ShowTables(_)
| Statement::ShowDatabases(_)
| Statement::Create(_)
| Statement::Alter(_)
| Statement::Insert(_) => unreachable!(),
}
}
}