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

hive解析"desc table"语法 会将操作误认为dropIndex #4067

Closed
axzhcode opened this issue Dec 2, 2020 · 1 comment
Closed

hive解析"desc table"语法 会将操作误认为dropIndex #4067

axzhcode opened this issue Dec 2, 2020 · 1 comment
Milestone

Comments

@axzhcode
Copy link

axzhcode commented Dec 2, 2020

如题。

List<SQLStatement> stmtList = SQLUtils.parseStatements("desc bi.aaa", DbType.hive);
SQLStatement stmt = stmtList.get(0);
SchemaStatVisitor statVisitor = SQLUtils.createSchemaStatVisitor(DbType.hive);
stmt.accept(statVisitor);
System.out.println(statVisitor.getTables());

输出为:
{bi.aaa=DropIndex}

@wenshao wenshao added this to the 1.2.4 milestone Dec 12, 2020
@wenshao
Copy link
Member

wenshao commented Dec 12, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants