Skip to content
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

Migrate show users/roles statement to new planner #6016

Merged
merged 1 commit into from
Jun 16, 2022

Conversation

junnplus
Copy link
Contributor

Signed-off-by: Ye Sijun junnplus@gmail.com

I hereby agree to the terms of the CLA available at: https://databend.rs/dev/policies/cla/

Summary

Summary about this PR

Changelog

  • New Feature

Related Issues

#5777

@vercel
Copy link

vercel bot commented Jun 16, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated
databend ⬜️ Ignored (Inspect) Jun 16, 2022 at 7:10AM (UTC)

@mergify
Copy link
Contributor

mergify bot commented Jun 16, 2022

Thanks for the contribution!
I have applied any labels matching special text in your PR Changelog.

Please review the labels and make any necessary changes.

@mergify mergify bot added the pr-feature this PR introduces a new feature to the codebase label Jun 16, 2022
@junnplus junnplus changed the title add show users/roles statement Migrate show users/roles statement to new planner Jun 16, 2022
@junnplus junnplus force-pushed the show-users branch 2 times, most recently from 8c21750 to c57b877 Compare June 16, 2022 05:10
@junnplus junnplus marked this pull request as ready for review June 16, 2022 05:59
@junnplus junnplus requested a review from TCeason June 16, 2022 05:59
@TCeason
Copy link
Collaborator

TCeason commented Jun 16, 2022

Need to add show in check func

   /// Check if statement is supported by InterpreterFactoryV2
    pub fn check(stmt: &DfStatement) -> bool {
        matches!(
            stmt,
            DfStatement::Query(_)
                | DfStatement::Explain(_)
                | DfStatement::CreateStage(_)
                | DfStatement::ShowStages(_)
                | DfStatement::DescribeStage(_)
                | DfStatement::List(_)
                | DfStatement::DropStage(_)
                | DfStatement::RemoveStage(_)
                | DfStatement::ShowDatabases(_)
                | DfStatement::ShowCreateDatabase(_)
                | DfStatement::ShowTables(_)
                | DfStatement::ShowCreateTable(_)
                | DfStatement::DescribeTable(_)
                | DfStatement::ShowTablesStatus(_)
                | DfStatement::CreateTable(_)
                | DfStatement::CreateView(_)
                | DfStatement::AlterView(_)
                | DfStatement::DropTable(_)
                | DfStatement::UndropTable(_)
                | DfStatement::AlterTable(_)
                | DfStatement::RenameTable(_)
                | DfStatement::TruncateTable(_)
                | DfStatement::OptimizeTable(_)
                | DfStatement::DropView(_)
                | DfStatement::ShowMetrics(_)
                | DfStatement::ShowProcessList(_)
                | DfStatement::ShowSettings(_)
                | DfStatement::CreateDatabase(_)
                | DfStatement::DropDatabase(_)
                | DfStatement::CreateUser(_)
                | DfStatement::AlterDatabase(_)
        )
    }

@TCeason
Copy link
Collaborator

TCeason commented Jun 16, 2022

/lgtm

Signed-off-by: Ye Sijun <junnplus@gmail.com>
@mergify mergify bot merged commit 9b1b1dd into databendlabs:main Jun 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
need-review pr-feature this PR introduces a new feature to the codebase
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants