From 1f3c09f9c3d371f862ee3bb3cf1352a35c52f338 Mon Sep 17 00:00:00 2001 From: niu niu Date: Wed, 25 Oct 2023 09:27:32 +0800 Subject: [PATCH] Fix oracle audit auditOperationClause rule (#28857) --- .../oracle/src/main/antlr4/imports/oracle/DDLStatement.g4 | 2 +- test/it/parser/src/main/resources/case/ddl/audit.xml | 5 +++++ .../it/parser/src/main/resources/sql/supported/ddl/audit.xml | 5 +++++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/parser/sql/dialect/oracle/src/main/antlr4/imports/oracle/DDLStatement.g4 b/parser/sql/dialect/oracle/src/main/antlr4/imports/oracle/DDLStatement.g4 index 4a12a7e533572..93039a8262ace 100644 --- a/parser/sql/dialect/oracle/src/main/antlr4/imports/oracle/DDLStatement.g4 +++ b/parser/sql/dialect/oracle/src/main/antlr4/imports/oracle/DDLStatement.g4 @@ -2268,7 +2268,7 @@ auditingByClause auditOperationClause : (sqlStatementShortcut | ALL | ALL STATEMENTS) (COMMA_ sqlStatementShortcut | ALL | ALL STATEMENTS)* - | (systemPrivilege | ALL PRIVILEGES) (COMMA_ systemPrivilege | ALL PRIVILEGES) + | (systemPrivilege | ALL PRIVILEGES) (COMMA_ systemPrivilege | ALL PRIVILEGES)* ; sqlStatementShortcut diff --git a/test/it/parser/src/main/resources/case/ddl/audit.xml b/test/it/parser/src/main/resources/case/ddl/audit.xml index d1784296d6abb..35c136b8e5dda 100644 --- a/test/it/parser/src/main/resources/case/ddl/audit.xml +++ b/test/it/parser/src/main/resources/case/ddl/audit.xml @@ -160,4 +160,9 @@ + + + + + diff --git a/test/it/parser/src/main/resources/sql/supported/ddl/audit.xml b/test/it/parser/src/main/resources/sql/supported/ddl/audit.xml index ce24256d545ff..63e68acebb05a 100644 --- a/test/it/parser/src/main/resources/sql/supported/ddl/audit.xml +++ b/test/it/parser/src/main/resources/sql/supported/ddl/audit.xml @@ -160,4 +160,9 @@ + + + + +