Skip to content

Commit

Permalink
Merge d25b7d8 into 3033b52
Browse files Browse the repository at this point in the history
  • Loading branch information
Genius-pig committed Jan 16, 2020
2 parents 3033b52 + d25b7d8 commit 26ff2b3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Expand Up @@ -42,7 +42,7 @@ statement
| DROP INDEX function=ID ON timeseriesPath #dropIndex //not support yet
| MERGE #merge //not support yet
| CREATE USER userName=ID password=STRING_LITERAL #createUser
| ALTER USER userName=ID SET PASSWORD password=STRING_LITERAL #alterUser
| ALTER USER userName=(ROOT|ID) SET PASSWORD password=STRING_LITERAL #alterUser
| DROP USER userName=ID #dropUser
| CREATE ROLE roleName=ID #createRole
| DROP ROLE roleName=ID #dropRole
Expand Down
Expand Up @@ -384,7 +384,11 @@ public void enterAlterUser(AlterUserContext ctx) {
super.enterAlterUser(ctx);
AuthorOperator authorOperator = new AuthorOperator(SQLConstant.TOK_AUTHOR_UPDATE_USER,
AuthorOperator.AuthorType.UPDATE_USER);
authorOperator.setUserName(ctx.ID().getText());
if(ctx.ID() != null) {
authorOperator.setUserName(ctx.ID().getText());
} else {
authorOperator.setUserName(ctx.ROOT().getText());
}
authorOperator.setNewPassword(removeStringQuote(ctx.password.getText()));
initializedOperator = authorOperator;
operatorType = SQLConstant.TOK_AUTHOR_UPDATE_USER;
Expand Down

0 comments on commit 26ff2b3

Please sign in to comment.