Skip to content

Commit

Permalink
opt: add support for CREATE TRIGGER in optimizer
Browse files Browse the repository at this point in the history
This commit finalizes support for `CREATE TRIGGER` by adding support
for it in the optimizer. This includes validation for the statement,
dependency resolution, and logic tests.

Fixes cockroachdb#126359

Release note (sql change): Added support for CREATE TRIGGER. Note that
OR REPLACE syntax is not yet supported. Also note that triggers cannot
yet be executed, so creation is currently a no-op.
  • Loading branch information
DrewKimball committed Oct 12, 2024
1 parent 9fb8eeb commit 0b647ac
Show file tree
Hide file tree
Showing 48 changed files with 2,843 additions and 60 deletions.
845 changes: 845 additions & 0 deletions pkg/ccl/logictestccl/testdata/logic_test/triggers

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ go_test(
"//pkg/ccl/logictestccl:testdata", # keep
],
exec_properties = {"test.Pool": "large"},
shard_count = 30,
shard_count = 29,
tags = ["cpu:1"],
deps = [
"//pkg/base",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/ccl/logictestccl/tests/local-mixed-24.1/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ go_test(
"//pkg/ccl/logictestccl:testdata", # keep
],
exec_properties = {"test.Pool": "large"},
shard_count = 29,
shard_count = 28,
tags = ["cpu:1"],
deps = [
"//pkg/base",
Expand Down
7 changes: 0 additions & 7 deletions pkg/ccl/logictestccl/tests/local-mixed-24.1/generated_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pkg/ccl/logictestccl/tests/local-mixed-24.2/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ go_test(
"//pkg/ccl/logictestccl:testdata", # keep
],
exec_properties = {"test.Pool": "large"},
shard_count = 30,
shard_count = 29,
tags = ["cpu:1"],
deps = [
"//pkg/base",
Expand Down
7 changes: 0 additions & 7 deletions pkg/ccl/logictestccl/tests/local-mixed-24.2/generated_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 0b647ac

Please sign in to comment.