Skip to content

Commit

Permalink
fix(grammar): SET isn't always a reserved keyword, it can be used as …
Browse files Browse the repository at this point in the history
…a object name
  • Loading branch information
felipebz committed Jun 23, 2024
1 parent a2b45d2 commit 6fc3fe1
Show file tree
Hide file tree
Showing 8 changed files with 37 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1521,7 +1521,7 @@
2
],
"sqlrf/ALTER-TABLE-8.sql" : [
4
3
],
"sqlrf/ALTER-TABLE-81.sql" : [
2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,13 @@
197,
371
],
"src/addons/pljson_object_cache.impl.sql" : [
42,
43,
44,
45,
46
],
"src/addons/pljson_util_pkg.package.sql" : [
345,
346,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,24 @@
464,
464
],
"src/addons/pljson_object_cache.decl.sql" : [
19,
20,
26,
26,
27,
28,
28
],
"src/addons/pljson_object_cache.impl.sql" : [
7,
17,
55,
55,
66,
82,
82
],
"src/addons/pljson_table_impl.type.decl.sql" : [
131,
131,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
{
"examples/ex_pljson_table.sql" : [
200
],
"src/addons/pljson_object_cache.decl.sql" : [
28
],
"src/addons/pljson_object_cache.impl.sql" : [
82
]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"src/addons/pljson_object_cache.impl.sql" : [
19
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
"src/addons/pljson_helper.package.sql" : [
243
],
"src/addons/pljson_object_cache.impl.sql" : [
21,
77
],
"src/addons/pljson_table_impl.type.impl.sql" : [
380,
656
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ enum class DmlGrammar : GrammarRuleKey {
OBJECT_REFERENCE
),
b.optional(NESTED_CLAUSE),
b.optional(b.nextNot(b.firstOf(PARTITION, CROSS, USING, FULL, NATURAL, INNER, LEFT, RIGHT, OUTER, JOIN, RETURN, RETURNING, LOG, EXCEPT)),
b.optional(b.nextNot(b.firstOf(PARTITION, CROSS, USING, FULL, NATURAL, INNER, LEFT, RIGHT, OUTER, JOIN, RETURN, RETURNING, LOG, EXCEPT, SET)),
b.optional(AS),
ALIAS
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ enum class PlSqlKeyword(override val value: String, val isReserved: Boolean = fa
RESOURCE("resource", true),
REVOKE("revoke", true),
SELECT("select", true),
SET("set", true),
SHARE("share", true),
SIZE("size", true),
SMALLINT("smallint"),
Expand Down Expand Up @@ -465,6 +464,7 @@ enum class PlSqlKeyword(override val value: String, val isReserved: Boolean = fa
SECOND("second"),
SEGMENT("segment"),
SELF("self"),
SET("set"),
SEQUENCE("sequence"),
SERIALIZABLE("serializable"),
SERIALLY_REUSABLE("serially_reusable"),
Expand Down

0 comments on commit 6fc3fe1

Please sign in to comment.