-
Notifications
You must be signed in to change notification settings - Fork 4k
sql: disallow creating partial stats by default #98500
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
sql: disallow creating partial stats by default #98500
Conversation
michae2
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Looks like some logic tests need to be rewritten.)
Reviewed 5 of 5 files at r1, all commit messages.
Reviewable status:complete! 1 of 0 LGTMs obtained (waiting on @mgartner)
pkg/sql/logictest/testdata/logic_test/distsql_stats line 2008 at r1 (raw file):
statement ok SET enable_create_stats_using_extremes = on
I think this will also need to be enabled in pkg/sql/opt/exec/execbuilder/testdata/partial_stats.
This commit adds the `enable_create_stats_using_extremes` session setting which allows users to run `CREATE STATISTICS .. USING EXTREMES` when enabled. It is disabled by default. This commit also presents a "feature not supported" error when a user tries to create partial statistics with a `WHERE` clause. This feature has not yet been implemented. Epic: CRDB-19449 Release note: None
80383de to
240ad78
Compare
mgartner
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status:
complete! 1 of 0 LGTMs obtained (waiting on @michae2)
pkg/sql/logictest/testdata/logic_test/distsql_stats line 2008 at r1 (raw file):
Previously, michae2 (Michael Erickson) wrote…
I think this will also need to be enabled in
pkg/sql/opt/exec/execbuilder/testdata/partial_stats.
It's actually not needed because we inject partial stats there instead of running CREATE STATISTICS .. USING EXTREMES.
|
TFTRs! bors r+ |
|
Build failed (retrying...): |
|
Build succeeded: |
This commit adds the
enable_create_stats_using_extremessessionsetting which allows users to run
CREATE STATISTICS .. USING EXTREMESwhen enabled. It is disabled by default.
This commit also presents a "feature not supported" error when a user
tries to create partial statistics with a
WHEREclause. This featurehas not yet been implemented.
Epic: CRDB-19449
Fixes #95233
Release note: None