From dda623e229a80c3628af2af08235852c27911399 Mon Sep 17 00:00:00 2001 From: Yahor Yuzefovich Date: Tue, 7 May 2024 18:03:29 -0700 Subject: [PATCH 1/5] sql: don't use SetWithPlanner for `password_encryption` Using the default Set method is sufficient. Release note: None --- pkg/sql/pg_catalog.go | 2 +- pkg/sql/vars.go | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/pkg/sql/pg_catalog.go b/pkg/sql/pg_catalog.go index 663a559b268a..5b2a26451aca 100644 --- a/pkg/sql/pg_catalog.go +++ b/pkg/sql/pg_catalog.go @@ -2905,7 +2905,7 @@ https://www.postgresql.org/docs/9.5/catalog-pg-settings.html`, valueDatum := tree.NewDString(value) var bootDatum tree.Datum = tree.DNull var resetDatum tree.Datum = tree.DNull - if gen.Set == nil && gen.RuntimeSet == nil { + if gen.Set == nil && gen.RuntimeSet == nil && gen.SetWithPlanner == nil { // RESET/SET will leave the variable unchanged. Announce the // current value as boot/reset value. bootDatum = valueDatum diff --git a/pkg/sql/vars.go b/pkg/sql/vars.go index c5aead5ae124..eed71cea33f7 100644 --- a/pkg/sql/vars.go +++ b/pkg/sql/vars.go @@ -1443,13 +1443,16 @@ var varGen = map[string]sessionVar{ Get: func(evalCtx *extendedEvalContext, _ *kv.Txn) (string, error) { return security.GetConfiguredPasswordHashMethod(&evalCtx.Settings.SV).String(), nil }, - SetWithPlanner: func(ctx context.Context, p *planner, local bool, val string) error { - method := security.GetConfiguredPasswordHashMethod(&p.ExecCfg().Settings.SV) - if val != method.String() { + Set: func(_ context.Context, m sessionDataMutator, s string) error { + method := security.GetConfiguredPasswordHashMethod(&m.settings.SV) + if s != method.String() { return newCannotChangeParameterError("password_encryption") } return nil }, + GlobalDefault: func(sv *settings.Values) string { + return security.GetConfiguredPasswordHashMethod(sv).String() + }, }, // Supported for PG compatibility only. From 0572ae26bdc718b51d81d6d4f884d7aca8736ad7 Mon Sep 17 00:00:00 2001 From: Yahor Yuzefovich Date: Wed, 8 May 2024 11:38:20 -0700 Subject: [PATCH 2/5] sql: fix the type of copy_num_retries_per_batch We were incorrectly using the boolean getter for this integer variable. The bug was introduced when this variable was added in 1c1d3133e754e08a2837f3dadf7e670ebf2242a7. Release note: None --- pkg/sql/logictest/testdata/logic_test/set | 4 ++++ pkg/sql/vars.go | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/pkg/sql/logictest/testdata/logic_test/set b/pkg/sql/logictest/testdata/logic_test/set index bfb9c09b5952..93df1c47e6bd 100644 --- a/pkg/sql/logictest/testdata/logic_test/set +++ b/pkg/sql/logictest/testdata/logic_test/set @@ -912,3 +912,7 @@ SHOW application_name · subtest end + +# Regression test for incorrectly marking this variable as boolean. +statement ok +SET copy_num_retries_per_batch = 5; diff --git a/pkg/sql/vars.go b/pkg/sql/vars.go index eed71cea33f7..8e04906b8f4a 100644 --- a/pkg/sql/vars.go +++ b/pkg/sql/vars.go @@ -2313,7 +2313,7 @@ var varGen = map[string]sessionVar{ // CockroachDB extension. `copy_num_retries_per_batch`: { - GetStringVal: makePostgresBoolGetStringValFn(`copy_num_retries_per_batch`), + GetStringVal: makeIntGetStringValFn(`copy_num_retries_per_batch`), Set: func(_ context.Context, m sessionDataMutator, s string) error { b, err := strconv.ParseInt(s, 10, 64) if err != nil { From 5e2874e7e3dd7095806da9d4fa9578cd7591a43c Mon Sep 17 00:00:00 2001 From: Yahor Yuzefovich Date: Tue, 7 May 2024 20:13:12 -0700 Subject: [PATCH 3/5] sql: fix cost_scans_with_default_col_size This commit fixes an omission where `cost_scans_with_default_col_size` session variable didn't actually use the corresponding cluster setting for its default value. In other words, the cluster setting actually had no effect. The bug has been present since this variable was introduced in af32d9dc887e3a6771013dc49293ae83cbe07dd4. Release note: None --- pkg/sql/vars.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/sql/vars.go b/pkg/sql/vars.go index 8e04906b8f4a..349bbbb16431 100644 --- a/pkg/sql/vars.go +++ b/pkg/sql/vars.go @@ -2251,7 +2251,9 @@ var varGen = map[string]sessionVar{ Get: func(evalCtx *extendedEvalContext, _ *kv.Txn) (string, error) { return formatBoolAsPostgresSetting(evalCtx.SessionData().CostScansWithDefaultColSize), nil }, - GlobalDefault: globalFalse, + GlobalDefault: func(sv *settings.Values) string { + return formatBoolAsPostgresSetting(costScansWithDefaultColSize.Get(sv)) + }, }, // CockroachDB extension. From 9e574d5c8931557c57441daa6dcd9fce46fdfba6 Mon Sep 17 00:00:00 2001 From: Yahor Yuzefovich Date: Tue, 7 May 2024 18:39:49 -0700 Subject: [PATCH 4/5] sql: fix up defaults for a few session variables This commit adjusts global defaults for a few session variables to use the postgres style (so that the global default value and session variable value would be stored alike). Release note: None --- pkg/sql/logictest/testdata/logic_test/pg_catalog | 6 +++--- pkg/sql/vars.go | 12 ++++-------- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/pkg/sql/logictest/testdata/logic_test/pg_catalog b/pkg/sql/logictest/testdata/logic_test/pg_catalog index 5000cef75129..0b67f9efa132 100644 --- a/pkg/sql/logictest/testdata/logic_test/pg_catalog +++ b/pkg/sql/logictest/testdata/logic_test/pg_catalog @@ -2974,7 +2974,7 @@ allow_ordinal_column_references off N allow_role_memberships_to_change_during_transaction off NULL user NULL off off alter_primary_region_super_region_override off NULL user NULL off off application_name · NULL user NULL · · -avoid_buffering off NULL user NULL false false +avoid_buffering off NULL user NULL off off backslash_quote safe_encoding NULL user NULL safe_encoding safe_encoding bytea_output hex NULL user NULL hex hex check_function_bodies on NULL user NULL on on @@ -3085,7 +3085,7 @@ optimizer_use_provided_ordering_fix on N optimizer_use_trigram_similarity_optimization off NULL user NULL off off optimizer_use_virtual_computed_column_stats off NULL user NULL off off override_multi_region_zone_config off NULL user NULL off off -parallelize_multi_key_lookup_joins_enabled off NULL user NULL false false +parallelize_multi_key_lookup_joins_enabled off NULL user NULL off off password_encryption scram-sha-256 NULL user NULL scram-sha-256 scram-sha-256 pg_trgm.similarity_threshold 0.3 NULL user NULL 0.3 0.3 prefer_lookup_joins_for_fks off NULL user NULL off off @@ -3131,7 +3131,7 @@ transaction_rows_read_log 0 N transaction_rows_written_err 0 NULL user NULL 0 0 transaction_rows_written_log 0 NULL user NULL 0 0 transaction_status NoTxn NULL user NULL NoTxn NoTxn -transaction_timeout 0 NULL user NULL 0 0 +transaction_timeout 0 NULL user NULL 0s 0s troubleshooting_mode off NULL user NULL off off unbounded_parallel_scans off NULL user NULL off off unconstrained_non_covering_index_scan_enabled off NULL user NULL off off diff --git a/pkg/sql/vars.go b/pkg/sql/vars.go index 349bbbb16431..487c9810f2fb 100644 --- a/pkg/sql/vars.go +++ b/pkg/sql/vars.go @@ -203,9 +203,7 @@ var varGen = map[string]sessionVar{ m.SetAvoidBuffering(b) return nil }, - GlobalDefault: func(sv *settings.Values) string { - return "false" - }, + GlobalDefault: globalFalse, }, // See https://www.postgresql.org/docs/10/static/runtime-config-client.html @@ -778,9 +776,7 @@ var varGen = map[string]sessionVar{ Get: func(evalCtx *extendedEvalContext, _ *kv.Txn) (string, error) { return "on", nil }, - GlobalDefault: func(sv *settings.Values) string { - return "on" - }, + GlobalDefault: globalTrue, }, // CockroachDB extension. @@ -1334,7 +1330,7 @@ var varGen = map[string]sessionVar{ return strconv.FormatInt(ms, 10), nil }, GlobalDefault: func(sv *settings.Values) string { - return strconv.FormatInt(0, 10) + return "0s" }, }, @@ -2231,7 +2227,7 @@ var varGen = map[string]sessionVar{ return formatBoolAsPostgresSetting(evalCtx.SessionData().ParallelizeMultiKeyLookupJoinsEnabled), nil }, GlobalDefault: func(sv *settings.Values) string { - return rowexec.ParallelizeMultiKeyLookupJoinsEnabled.String(sv) + return formatBoolAsPostgresSetting(rowexec.ParallelizeMultiKeyLookupJoinsEnabled.Get(sv)) }, }, From 69d118ccd4fb10bf1446de75b2f1762a8d741626 Mon Sep 17 00:00:00 2001 From: Yahor Yuzefovich Date: Wed, 8 May 2024 09:46:06 -0700 Subject: [PATCH 5/5] sql: improve env collection in stmt bundles This commit refactors how we collect session variables and cluster settings into `env.sql` file in the stmt bundle. Previously, we used a hard-coded list of session variables that were always included while ignoring all variables not in the list. If a variable had a value different from the "binary default" (meaning the value that you got right after the cluster startup, before any cluster setting modifications are applied), then it would be in a SET statement that would run on the `bundle recreate`; if the value was the same as "binary default", then the SET statement was commented out. Also, all cluster setting values were included into the file as a comment. This commit makes it so that we include all session variables and cluster settings that differ from their defaults. This allows us to recreate the environment while also reducing the overhead of including everything into `env.sql`. For session variables further clarification is warranted: - all read-only variables have been audited, and most are explicitly excluded. Out of 23 currently present session variables, only 9 were deemed to be possibly useful during investigations, so they are not excluded (one of 9 is `crdb_version` which we print out separately, so it's actually excluded too). - for writable variables, we include it if its value differs from the "binary" default (the one that you get on a fresh cluster) or from the "cluster" default (the one that you get on a fresh session on the current cluster). The latter kind is obtained via the provided `settings.Values` container whereas the former is obtained via a global singleton container. Additionally, this commit adjusts the SET and SET CLUSTER SETTING statements to have single quotes around the setting values that need them. For cluster settings all types work with having single quotes, but for session variables some (like integers) don't work with quotes while others (like strings) need them. This commit adds a map for those that need them as well as a simple test to catch some of the missing ones (the list might be incomplete given that the test exercises the default config). All values are adjusted to fit on a single line (we have some cluster settings that might span multiple lines). It also adjusts `EXPLAIN (OPT, ENV)` to include the list of cluster settings with non-default values. Release note: None --- pkg/sql/explain_bundle.go | 347 ++++++++++-------- pkg/sql/explain_bundle_test.go | 49 +++ pkg/sql/instrumentation.go | 2 +- .../opt/exec/execbuilder/testdata/explain_env | 36 +- pkg/sql/opt_exec_factory.go | 12 +- 5 files changed, 272 insertions(+), 174 deletions(-) diff --git a/pkg/sql/explain_bundle.go b/pkg/sql/explain_bundle.go index b07dd0aad636..051999cc9d79 100644 --- a/pkg/sql/explain_bundle.go +++ b/pkg/sql/explain_bundle.go @@ -18,22 +18,22 @@ import ( "regexp" "strconv" "strings" + "time" + "unicode" "github.com/cockroachdb/cockroach/pkg/kv" "github.com/cockroachdb/cockroach/pkg/settings" + "github.com/cockroachdb/cockroach/pkg/settings/cluster" "github.com/cockroachdb/cockroach/pkg/sql/catalog/catalogkeys" "github.com/cockroachdb/cockroach/pkg/sql/catalog/colinfo" - "github.com/cockroachdb/cockroach/pkg/sql/colfetcher" "github.com/cockroachdb/cockroach/pkg/sql/opt/cat" "github.com/cockroachdb/cockroach/pkg/sql/opt/exec/explain" "github.com/cockroachdb/cockroach/pkg/sql/opt/memo" "github.com/cockroachdb/cockroach/pkg/sql/sem/catconstants" "github.com/cockroachdb/cockroach/pkg/sql/sem/tree" "github.com/cockroachdb/cockroach/pkg/sql/sessiondata" - "github.com/cockroachdb/cockroach/pkg/sql/sessiondatapb" "github.com/cockroachdb/cockroach/pkg/sql/stmtdiagnostics" "github.com/cockroachdb/cockroach/pkg/util/buildutil" - "github.com/cockroachdb/cockroach/pkg/util/duration" "github.com/cockroachdb/cockroach/pkg/util/log" "github.com/cockroachdb/cockroach/pkg/util/memzipper" "github.com/cockroachdb/cockroach/pkg/util/pretty" @@ -138,6 +138,7 @@ func buildStatementBundle( ctx context.Context, explainFlags explain.Flags, db *kv.DB, + p *planner, ie *InternalExecutor, stmtRawSQL string, plan *planTop, @@ -151,7 +152,7 @@ func buildStatementBundle( if plan == nil { return diagnosticsBundle{collectionErr: errors.AssertionFailedf("execution terminated early")} } - b, err := makeStmtBundleBuilder(explainFlags, db, ie, stmtRawSQL, plan, trace, placeholders, sv) + b, err := makeStmtBundleBuilder(explainFlags, db, p, ie, stmtRawSQL, plan, trace, placeholders, sv) if err != nil { return diagnosticsBundle{collectionErr: err} } @@ -209,6 +210,7 @@ type stmtBundleBuilder struct { flags explain.Flags db *kv.DB + p *planner ie *InternalExecutor stmt string @@ -226,6 +228,7 @@ type stmtBundleBuilder struct { func makeStmtBundleBuilder( flags explain.Flags, db *kv.DB, + p *planner, ie *InternalExecutor, stmtRawSQL string, plan *planTop, @@ -234,7 +237,7 @@ func makeStmtBundleBuilder( sv *settings.Values, ) (stmtBundleBuilder, error) { b := stmtBundleBuilder{ - flags: flags, db: db, ie: ie, plan: plan, trace: trace, placeholders: placeholders, sv: sv, + flags: flags, db: db, p: p, ie: ie, plan: plan, trace: trace, placeholders: placeholders, sv: sv, } err := b.buildPrettyStatement(stmtRawSQL) if err != nil { @@ -535,7 +538,7 @@ func (b *stmtBundleBuilder) printError(errString string, buf *bytes.Buffer) { } func (b *stmtBundleBuilder) addEnv(ctx context.Context) { - c := makeStmtEnvCollector(ctx, b.ie) + c := makeStmtEnvCollector(ctx, b.p, b.ie) var buf bytes.Buffer if err := c.PrintVersion(&buf); err != nil { @@ -543,14 +546,13 @@ func (b *stmtBundleBuilder) addEnv(ctx context.Context) { } fmt.Fprintf(&buf, "\n") - // Show the values of session variables that can impact planning decisions. - if err := c.PrintSessionSettings(&buf, b.sv); err != nil { + // Show the values of session variables and cluster settings that have + // values different from their defaults. + if err := c.PrintSessionSettings(&buf, b.sv, false /* all */); err != nil { b.printError(fmt.Sprintf("-- error getting session settings: %v", err), &buf) } - fmt.Fprintf(&buf, "\n") - - if err := c.PrintClusterSettings(&buf); err != nil { + if err := c.PrintClusterSettings(&buf, false /* all */); err != nil { b.printError(fmt.Sprintf("-- error getting cluster settings: %v", err), &buf) } @@ -702,11 +704,12 @@ func (b *stmtBundleBuilder) finalize() (*bytes.Buffer, error) { // schema, table statistics. type stmtEnvCollector struct { ctx context.Context + p *planner ie *InternalExecutor } -func makeStmtEnvCollector(ctx context.Context, ie *InternalExecutor) stmtEnvCollector { - return stmtEnvCollector{ctx: ctx, ie: ie} +func makeStmtEnvCollector(ctx context.Context, p *planner, ie *InternalExecutor) stmtEnvCollector { + return stmtEnvCollector{ctx: ctx, p: p, ie: ie} } // query is a helper to run a query that returns a single string value. @@ -800,179 +803,181 @@ func (c *stmtEnvCollector) PrintVersion(w io.Writer) error { return err } -// PrintSessionSettings appends information about session settings that can -// impact planning decisions. -func (c *stmtEnvCollector) PrintSessionSettings(w io.Writer, sv *settings.Values) error { - // Cluster setting encoded default value to session setting value conversion - // functions. - boolToOnOff := func(boolStr string) string { - switch boolStr { - case "true": - return "on" - case "false": - return "off" +// makeSingleLine replaces all control characters with a single space. This is +// needed so that session variables and cluster settings would fit on a single +// line. +func makeSingleLine(s string) string { + return strings.Map(func(r rune) rune { + if unicode.IsControl(r) { + return ' ' } - return boolStr - } + return r + }, s) +} - datestyleConv := func(enumVal string) string { - n, err := strconv.ParseInt(enumVal, 10, 32) - if err != nil || n < 0 || n >= int64(len(dateStyleEnumMap)) { - return enumVal - } - return dateStyleEnumMap[n] - } +// binarySVForBundle is a Values container that can be used to access "binary +// defaults" of session variables. +var binarySVForBundle *settings.Values - intervalstyleConv := func(enumVal string) string { - n, err := strconv.ParseInt(enumVal, 10, 32) - if err != nil || n < 0 || n >= int64(len(duration.IntervalStyle_name)) { - return enumVal - } - return strings.ToLower(duration.IntervalStyle(n).String()) - } - - distsqlConv := func(enumVal string) string { - n, err := strconv.ParseInt(enumVal, 10, 32) - if err != nil { - return enumVal - } - return sessiondatapb.DistSQLExecMode(n).String() - } +func init() { + // Using a "testing" method seems a bit sketchy but is ok for our purposes. + st := cluster.MakeTestingClusterSettings() + binarySVForBundle = &st.SV +} - vectorizeConv := func(enumVal string) string { - n, err := strconv.ParseInt(enumVal, 10, 32) +// PrintSessionSettings appends information about all session variables that +// differ from their defaults. +// +// If all is true, then all variables are included. +func (c *stmtEnvCollector) PrintSessionSettings(w io.Writer, sv *settings.Values, all bool) error { + // When thinking about a "default" value for a session variable, there might + // be two options: + // - the "binary" default - this is the value that the variable gets on a + // new session on a fresh cluster + // - the "cluster" default - this is the value that the variable gets on a + // new session on this cluster (which might have some modified cluster + // settings that provide defaults). + // Using the given Values provides us access to the latter, and we use the + // global singleton container for the former. + binarySV, clusterSV := binarySVForBundle, sv + for _, varName := range varNames { + gen := varGen[varName] + value, err := gen.Get(&c.p.extendedEvalCtx, c.p.Txn()) if err != nil { - return enumVal + return err } - return sessiondatapb.VectorizeExecMode(n).String() - } - - timeoutConv := func(timeoutStr string) string { - // Currently, all supported timeouts have 0 default value, so we'll - // assert that in tests. - if timeoutStr != "0s" { + value = makeSingleLine(value) + if gen.Set == nil && gen.RuntimeSet == nil && gen.SetWithPlanner == nil { + // Read-only variable. if buildutil.CrdbTestBuild { - panic(errors.AssertionFailedf("unexpected default value for a timeout setting %s", timeoutStr)) + // Skip all read-only variables in tests. + continue + } + if _, skip := skipReadOnlySessionVar[varName]; skip { + // Skip it since its value is unlikely to be useful. + continue + } + fmt.Fprintf(w, "-- read-only %s = %s\n", varName, value) + continue + } + maybeAdjustTimeout := func(value string) (string, error) { + switch varName { + case "idle_in_session_timeout", "idle_in_transaction_session_timeout", + "idle_session_timeout", "lock_timeout", "statement_timeout", "transaction_timeout": + // Defaults for timeout settings are of the duration type (i.e. + // "0s"), so we'll parse it to extract the number of + // milliseconds (which is what the session variable uses). + d, err := time.ParseDuration(value) + if err != nil { + return "", err + } + return strconv.Itoa(int(d.Milliseconds())), nil + default: + return value, nil } - return timeoutStr } - return "0" - } - - // TODO(rytaft): Keeping this list up to date is a challenge. Consider just - // printing all session settings. - relevantSettings := []struct { - sessionSetting string - clusterSetting settings.NonMaskedSetting - convFunc func(string) string - }{ - {sessionSetting: "allow_prepare_as_opt_plan"}, - {sessionSetting: "cost_scans_with_default_col_size", clusterSetting: costScansWithDefaultColSize, convFunc: boolToOnOff}, - {sessionSetting: "datestyle", clusterSetting: dateStyle, convFunc: datestyleConv}, - {sessionSetting: "default_int_size", clusterSetting: defaultIntSize}, - {sessionSetting: "default_transaction_priority"}, - {sessionSetting: "default_transaction_quality_of_service"}, - {sessionSetting: "default_transaction_read_only"}, - {sessionSetting: "default_transaction_use_follower_reads"}, - {sessionSetting: "direct_columnar_scans_enabled", clusterSetting: colfetcher.DirectScansEnabled, convFunc: boolToOnOff}, - {sessionSetting: "disallow_full_table_scans", clusterSetting: disallowFullTableScans, convFunc: boolToOnOff}, - {sessionSetting: "distsql", clusterSetting: DistSQLClusterExecMode, convFunc: distsqlConv}, - {sessionSetting: "enable_implicit_select_for_update", clusterSetting: implicitSelectForUpdateClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "enable_implicit_transaction_for_batch_statements"}, - {sessionSetting: "enable_insert_fast_path", clusterSetting: insertFastPathClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "enable_multiple_modifications_of_table"}, - {sessionSetting: "enable_zigzag_join", clusterSetting: zigzagJoinClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "expect_and_ignore_not_visible_columns_in_copy"}, - {sessionSetting: "idle_in_transaction_session_timeout", clusterSetting: clusterIdleInTransactionSessionTimeout, convFunc: timeoutConv}, - {sessionSetting: "idle_session_timeout", clusterSetting: clusterIdleInSessionTimeout, convFunc: timeoutConv}, - {sessionSetting: "intervalstyle", clusterSetting: intervalStyle, convFunc: intervalstyleConv}, - {sessionSetting: "large_full_scan_rows", clusterSetting: largeFullScanRows}, - {sessionSetting: "locality_optimized_partitioned_index_scan", clusterSetting: localityOptimizedSearchMode, convFunc: boolToOnOff}, - {sessionSetting: "lock_timeout", clusterSetting: clusterLockTimeout, convFunc: timeoutConv}, - {sessionSetting: "null_ordered_last"}, - {sessionSetting: "on_update_rehome_row_enabled", clusterSetting: onUpdateRehomeRowEnabledClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "opt_split_scan_limit"}, - {sessionSetting: "optimizer_apply_full_scan_penalty_to_virtual_tables", convFunc: boolToOnOff}, - {sessionSetting: "optimizer_use_forecasts", convFunc: boolToOnOff}, - {sessionSetting: "optimizer_use_histograms", clusterSetting: optUseHistogramsClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "optimizer_use_multicol_stats", clusterSetting: optUseMultiColStatsClusterMode, convFunc: boolToOnOff}, - {sessionSetting: "optimizer_use_not_visible_indexes"}, - {sessionSetting: "pg_trgm.similarity_threshold"}, - {sessionSetting: "prefer_lookup_joins_for_fks", clusterSetting: preferLookupJoinsForFKs, convFunc: boolToOnOff}, - {sessionSetting: "propagate_input_ordering", clusterSetting: propagateInputOrdering, convFunc: boolToOnOff}, - {sessionSetting: "reorder_joins_limit", clusterSetting: ReorderJoinsLimitClusterValue}, - {sessionSetting: "sql_safe_updates"}, - {sessionSetting: "statement_timeout", clusterSetting: clusterStatementTimeout, convFunc: timeoutConv}, - {sessionSetting: "testing_optimizer_cost_perturbation"}, - {sessionSetting: "testing_optimizer_disable_rule_probability"}, - {sessionSetting: "testing_optimizer_random_seed"}, - {sessionSetting: "timezone"}, - {sessionSetting: "transaction_timeout"}, - {sessionSetting: "unbounded_parallel_scans"}, - {sessionSetting: "unconstrained_non_covering_index_scan_enabled"}, - {sessionSetting: "vectorize", clusterSetting: VectorizeClusterMode, convFunc: vectorizeConv}, - } - - for _, s := range relevantSettings { - value, err := c.query(fmt.Sprintf("SHOW %s", s.sessionSetting)) + // All writable variables must have GlobalDefault set. + binaryDefault, err := maybeAdjustTimeout(makeSingleLine(gen.GlobalDefault(binarySV))) if err != nil { return err } - // Get the default value for the cluster setting. - var def string - if s.clusterSetting == nil { - if ok, v, _ := getSessionVar(s.sessionSetting, true); ok { - if v.GlobalDefault != nil { - def = v.GlobalDefault(sv) - } - } - } else { - def = s.clusterSetting.EncodedDefault() - if buildutil.CrdbTestBuild { - // In test builds we might randomize some setting defaults, so - // we need to override them to make the tests deterministic. - switch s.sessionSetting { - case "direct_columnar_scans_enabled": - def = "false" - } + clusterDefault, err := maybeAdjustTimeout(makeSingleLine(gen.GlobalDefault(clusterSV))) + if err != nil { + return err + } + // We'll skip this variable only if its value matches both of the + // defaults. + skip := value == binaryDefault && value == clusterDefault + if buildutil.CrdbTestBuild { + // In test builds we might randomize some setting defaults, so + // we need to ignore them to make the tests deterministic. + switch varName { + case "direct_columnar_scans_enabled": + // This variable's default is randomized in test builds. + skip = true } } - if s.convFunc != nil { - // If necessary, convert the encoded cluster setting to a session setting - // value (e.g. "true"->"on"), depending on the setting. - def = s.convFunc(def) + // Use the "binary default" as the value that we will set to. + defaultValue := binaryDefault + if skip && !all { + continue } - - if value == def { - fmt.Fprintf(w, "-- %s has the default value: %s\n", s.sessionSetting, value) - } else { - fmt.Fprintf(w, "SET %s = %s; -- default value: %s\n", s.sessionSetting, value, def) + formatStr := `SET %s = %s; -- default value: %s` + if _, ok := sessionVarNeedsQuotes[varName]; ok { + formatStr = `SET %s = '%s'; -- default value: %s` + } + if value == "" { + // Need a special case for empty strings to make the SET statement + // parsable. + value = "''" } + if varName == "database" { + // Special case the 'database' session variable - since env.sql is + // executed _before_ schema.sql when recreating the bundle, the + // target database might not exist yet. + fmt.Fprintf(w, "-- SET database = '%s';\n", value) + continue + } + fmt.Fprintf(w, formatStr+"\n", varName, value, defaultValue) } return nil } -func (c *stmtEnvCollector) PrintClusterSettings(w io.Writer) error { +// PrintClusterSettings appends information about all cluster settings that +// differ from their binary defaults. +// +// If all is true, then all settings are included. +func (c *stmtEnvCollector) PrintClusterSettings(w io.Writer, all bool) error { // TODO(michae2): We should also query system.database_role_settings. + var suffix string + if !all { + suffix = " WHERE value != default_value" + } rows, err := c.ie.QueryBufferedEx( c.ctx, "stmtEnvCollector", nil, /* txn */ sessiondata.NoSessionDataOverride, - "SELECT variable, value, description FROM [ SHOW ALL CLUSTER SETTINGS ]", + fmt.Sprintf(`SELECT variable, value, default_value FROM crdb_internal.cluster_settings%s`, suffix), ) if err != nil { return err } - fmt.Fprintf(w, "-- Cluster settings:\n") for _, r := range rows { // The datums should always be DString, but we should be defensive. - variable, ok1 := r[0].(*tree.DString) + setting, ok1 := r[0].(*tree.DString) value, ok2 := r[1].(*tree.DString) - description, ok3 := r[2].(*tree.DString) + def, ok3 := r[2].(*tree.DString) if ok1 && ok2 && ok3 { - fmt.Fprintf(w, "-- %s = %s (%s)\n", *variable, *value, *description) + var skip bool + // Ignore some settings that might differ from their default values + // but aren't useful in stmt bundles. + switch *setting { + case "cluster.secret", "diagnostics.reporting.enabled", "enterprise.license", "version": + skip = true + } + if buildutil.CrdbTestBuild { + switch *setting { + case "sql.distsql.direct_columnar_scans.enabled": + // This setting's default is randomized in test builds. + skip = true + case "bulkio.import.constraint_validation.unsafe.enabled", + "kv.raft_log.synchronization.unsafe.disabled": + // These settings are marked as "unsafe", so skip them in + // the tests. + skip = true + } + } + if skip { + continue + } + // All cluster settings, regardless of the type, accept values in + // single quotes. + fmt.Fprintf( + w, "SET CLUSTER SETTING %s = '%s'; -- default value: %s\n", + *setting, makeSingleLine(string(*value)), makeSingleLine(string(*def)), + ) } } return nil @@ -1149,3 +1154,43 @@ func (c *stmtEnvCollector) PrintTableStats( fmt.Fprintf(w, "ALTER TABLE %s INJECT STATISTICS '%s';\n", tn.FQString(), stats) return nil } + +// skipReadOnlySessionVar contains all read-only session variables that are +// explicitly excluded from env.sql of the bundle (they were deemed unlikely to +// be useful in investigations). +var skipReadOnlySessionVar = map[string]struct{}{ + "crdb_version": {}, // version is included separately + "integer_datetimes": {}, + "lc_collate": {}, + "lc_ctype": {}, + "max_connections": {}, + "max_identifier_length": {}, + "max_index_keys": {}, + "server_encoding": {}, + "server_version": {}, + "server_version_num": {}, + "session_authorization": {}, + "session_user": {}, + "system_identity": {}, + "tracing": {}, + "virtual_cluster_name": {}, +} + +// sessionVarNeedsQuotes contains all writable session variables that have +// values that need single quotes around them in SET statements. +var sessionVarNeedsQuotes = map[string]struct{}{ + "application_name": {}, + "datestyle": {}, + "distsql_workmem": {}, + "index_join_streamer_batch_size": {}, + "join_reader_index_join_strategy_batch_size": {}, + "join_reader_no_ordering_strategy_batch_size": {}, + "join_reader_ordering_strategy_batch_size": {}, + "lc_messages": {}, + "lc_monetary": {}, + "lc_numeric": {}, + "lc_time": {}, + "password_encryption": {}, + "prepared_statements_cache_size": {}, + "timezone": {}, +} diff --git a/pkg/sql/explain_bundle_test.go b/pkg/sql/explain_bundle_test.go index 0164daf0d009..87e6cce74c3c 100644 --- a/pkg/sql/explain_bundle_test.go +++ b/pkg/sql/explain_bundle_test.go @@ -24,7 +24,9 @@ import ( "time" "github.com/cockroachdb/cockroach/pkg/base" + "github.com/cockroachdb/cockroach/pkg/kv" "github.com/cockroachdb/cockroach/pkg/kv/kvserver" + "github.com/cockroachdb/cockroach/pkg/security/username" "github.com/cockroachdb/cockroach/pkg/testutils" "github.com/cockroachdb/cockroach/pkg/testutils/serverutils" "github.com/cockroachdb/cockroach/pkg/testutils/sqlutils" @@ -597,3 +599,50 @@ SELECT a || $1 FROM t WHERE k = ($2 - $10); require.Equal(t, tc.numPlaceholders, p) } } + +// TestExplainBundleEnv is a sanity check that all SET and SET CLUSTER SETTING +// statements in the env.sql file of the bundle are valid. +func TestExplainBundleEnv(t *testing.T) { + defer leaktest.AfterTest(t)() + defer log.Scope(t).Close(t) + + ctx := context.Background() + srv, sqlDB, db := serverutils.StartServer(t, base.TestServerArgs{}) + defer srv.Stopper().Stop(ctx) + s := srv.ApplicationLayer() + + execCfg := s.ExecutorConfig().(ExecutorConfig) + sd := NewInternalSessionData(ctx, execCfg.Settings, "test") + internalPlanner, cleanup := NewInternalPlanner( + "test", + kv.NewTxn(ctx, db, srv.NodeID()), + username.RootUserName(), + &MemoryMetrics{}, + &execCfg, + sd, + ) + defer cleanup() + p := internalPlanner.(*planner) + c := makeStmtEnvCollector(ctx, p, s.InternalExecutor().(*InternalExecutor)) + + var sb strings.Builder + require.NoError(t, c.PrintSessionSettings(&sb, &s.ClusterSettings().SV, true /* all */)) + vars := strings.Split(sb.String(), "\n") + for _, line := range vars { + _, err := sqlDB.ExecContext(ctx, line) + if err != nil { + words := strings.Split(line, " ") + t.Fatalf("%v: probably need to add %q into 'sessionVarNeedsQuotes' map", err, words[1]) + } + } + + sb.Reset() + require.NoError(t, c.PrintClusterSettings(&sb, true /* all */)) + vars = strings.Split(sb.String(), "\n") + for _, line := range vars { + _, err := sqlDB.ExecContext(ctx, line) + if err != nil { + t.Fatalf("unexpectedly couldn't execute %s: %v", line, err) + } + } +} diff --git a/pkg/sql/instrumentation.go b/pkg/sql/instrumentation.go index 157a58128dec..356b6a530ffd 100644 --- a/pkg/sql/instrumentation.go +++ b/pkg/sql/instrumentation.go @@ -662,7 +662,7 @@ func (ih *instrumentationHelper) Finish( planString = "-- plan elided due to gist matching" } bundle = buildStatementBundle( - bundleCtx, ih.explainFlags, cfg.DB, ie.(*InternalExecutor), + bundleCtx, ih.explainFlags, cfg.DB, p, ie.(*InternalExecutor), stmtRawSQL, &p.curPlan, planString, trace, placeholders, res.ErrAllowReleased(), payloadErr, retErr, &p.extendedEvalCtx.Settings.SV, ih.inFlightTraceCollector, ) diff --git a/pkg/sql/opt/exec/execbuilder/testdata/explain_env b/pkg/sql/opt/exec/execbuilder/testdata/explain_env index c1d28af5fff9..c57b9d9b246f 100644 --- a/pkg/sql/opt/exec/execbuilder/testdata/explain_env +++ b/pkg/sql/opt/exec/execbuilder/testdata/explain_env @@ -39,7 +39,7 @@ CREATE TABLE y ( query T EXPLAIN (OPT, ENV) SELECT * FROM x WHERE b = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zYUvq6e4sA3TYY4kZNdBA4KzHXVzVvqFLbatSgKgpKOZC4UyZKUamcY0IfIE_ZJBlJK4mCRlWBoLoKIOd_h-fnOdzgcwnvUhkkxhqlML7Wk6erVS8A1pknFeIYaLBoLdWMVBMMhUM7lV6I0KqqRUEOkskRxKmBFDdgVQoY5rbiFmvIKxyDz3OFSaSwxKRWGfGV2RVorkkpODLvCHnhGXSQb3mk3W14cwJtXH71x65sJu9P36bax1VQYmlomBVGaSc3spgsopC4p70J_qShndkNkTgzqmqWdAWgsKk51lyONNCNS8M44borzALYySHLpmoXaOzJ9TpjG1PejKgXVba9Q0IRj1os1DS_yinNiHaTB78Ito9gBrfnC4YU7OQO4S-bGklZWuiuaQAgrFWcps8Qgd-HmUpNKOXZ0XiUegm-XyvlIqE1XxFhqsURhuwO_500Y1Jbk1FiiqF09ClRW3DLl_pAZy1lKXQzGkcXXrafSrZMrVlzRgvwlWd_c4Vq5OlGREVYIqZEIaUnNDHN-mm4bwgRJperjGct80veKZ9A4bSCWlSgr2-UhvMU_CSAs6prynZOvpLGFRuMA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AH2WfpBq8sV2VJOrH8gNpLueee87ljG3Da94oIWsfQsneN5Kyd8-fAe84y1tRFbwBzZWG7QGFkG1DijMoqKY5VRwuYWQAoyXqy0Jp9aGCS5BluQSwbSh4SdtKw5ZWLfeBtlr2UFEXvCMNZ3Kz4XVBtZC1IrymecWLLxAYEaY_XL1KM5wYNVkUvwD1oXJYU-RE1Jo3Na0cbahII38mSlMtlBZMOVQRWRItNr102_vjdzUanGN7rvrsoAesck6GR7Ish5mOloeYjDTlGMiGasEIk1XFmVmGc9rFqKSV4sPsumn5v2HfiNrs5bAhZYY8GR7wxHW_wl_KhjOqtPr_JKud0nxD-l-oiDFwqP-DAShMcJBhyIJnK9yn2Llr80owp4MxuqAQxdlTiNcZxK9Wqym6yB8qh1O4jtMsCaI4g47cvec7uE6il0HyFn7Ab2FMIUjDyRRdRPFz_AY6khNRdDDO-zqaLBEKVsbb0Pgo_h6HGaRZkEVpFoUpjG4QAMCv_ds8Ft3-RJT4hVs-uNNTmcmq3dTK8uHmWDzgreP59hzfcKp5Qai2fLDmrvfUdj3b9cD1fNf1Xdc6A5s0i5ppwmRbmwbPPZ_9TigtTYaI3t0ZYdZ5c91W1bHxvM3cwCPhfOHNF_2336b_1XL-KJZ7hY_nGt2Oll_I5s5ks_1bNrefy-ZuIJvtp2z-BbclpUFerRMcvYgPyO0EEnyFExyHOIVP-RzTU7BNXx_s7deDvRsMdu8Xv7leBVEM4_V1NgUcv55AilcG-w1cJeuX0MGP3-EEQw6XsFgi27ZtpBitofv24W4huN_v7_cf7_cfgcla6YaKWvswm888H25mC7BhtrhFfwYAAP__2JX34g== statement error pq: at or near "EOF": syntax error: the ENV flag can only be used with OPT @@ -52,7 +52,7 @@ EXPLAIN (ENV) SELECT * FROM x WHERE b = 3 query T EXPLAIN (OPT, ENV) SELECT * FROM x, y WHERE b = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt9u27YXvq6e4sA3TX6wEzn5XQQOCsx11c1b6hS22rUoCoKWjmQu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-SZQpJukjDJA2XCQyvEADAL923-wzY9gdq5M9iEIA3uS9zXdYbZQYBXB2Ke_zgcL4-xleCWZFTZgcBDM48_zH2fOz54PmB5wWeNzgCuzRLxS3lulauwfeOZ7-RxmqXIWrbGydscNys6rI8NB63uRd4IDyb-Wez7u7XyX-1nD2I5U7hw7lG18P5Z7LZumzWH2Vz-6lstj3ZrD9k82-4LS0c8mIdk_BZtEduxxCTCxKTaEkS-JDPEbsPtuvrgr39crDb3mB3fsmry9UijGC0vkwnQKKXY0jIymG_got4_RyaCbTw_TckJpDBOczmCGOMkVRKVPhHLRWMeKWNGSO43f1-u3t_u3sPhjMF7UeV5uu75-hufnNbv93t7gBcK2MrJpUN4PTs1A_g6nQGGE5n1-gIVsjSisrAyP2VjNFfAQAA___yoBv6 # # Same table twice should only show up once. @@ -61,7 +61,7 @@ https://cockroachdb.github.io/text/decode.html#eJy0Vt9u27YXvq6e4sA3TX6wEzn5XQQOC query T EXPLAIN (OPT, ENV) SELECT * FROM x one, x two ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vs1u2zgQPldPQfhSZ2EHcrqHwEEPrqsuvJvaha0WLYqCGEsjmRuKZElKsbNYoA-R4z5dnmRBSkkcbGQlWDSHwCLnm99vZjgckk-oDZNiTKYyudASks3bNwS3mKxLxlPUxKKxpKqlgmA4JMC5vKRKowKNFAyVylLFQZANGGI3SFLMoOSWVMBLHBOZZQ6XSGOpSUAYesnshjZSNJGcGnaFHfAUnCc73io3Wy0G5P3bL1640c2EPaj7dF_YahAGEsukoEozqZndtQGF1AXwNvT3EjizOyozalBXLGl1QGNectBtijRCSqXgrX7cJucRbGmQZtIVC7VXZLqUMI2Jr0dZCNBNrVDAmmPaiTU1L7KSc2odpMYfwq2i2AGt-c7Ja3dyRsh9MLeSUFrpTNSOUFYozhJmqUHu3M2kpqVy7Gg1JR6D76fK6ViDTTbUWLBYoLDtjj_QJgxqSzMwliqwmyeBipJbptwPmbKMJeB8MI4sPm8dmW6UXLH8CnL6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XeBT8GwAA__9m5NoY +https://cockroachdb.github.io/text/decode.html#eJy0VN1u2zYUvg6f4kA3tgdLkFIUKGzkQlWZQpsrB5JatAgCgqKolatMpiLlyBsG9CF8udfYC-xR8iQD5cT2MCXBfqILQTznO98539EnuS584I0WSs4gUuxLoyj7_OY18I6zohV1yRswXBtY71AIuS5kOIeSGlpQzeEMRhYwmqM-LLTRX2s4A1VVcwDXhZJXtK0NrGnd8hnQ1qgeKmTJO9JwplYrLktqhJKacEmLmpePENghbH20eJ_lOLXT5HHyFvTX2mNNWRAhDW8krT1jqUijbog21AhtBNMe1URVxIhVP7ob_PG7Hg32cQNfP9joDqu9g-CRqqphpr3kISY7mvYsZEWNYISpuubMLsM77GJU0VrzYXbTtPzfsK-EtHvZbUjbJi-HG7z0_Sf4K9VwRrXR_9_IeqMNX5H-FWpiBezi_6ABilIc5hjy8PUC9y72rtuiFszrYIxOKMRJ_gqSZQ7J-8Viik6Ku8juFC2TLE_DOMmhI9df-AYu0vhdmH6CH_AnGFMIs2gyRSdx8gZ_hI4URJQdjIs-jiZzhMKF1TbUPk6-x1EOWR7mcZbHUQajSwQA8Et_t5dD1z8SLX7mzgz86SHMVN2upHZmcLkP7vDO_nx1jG84Nbwk1DgzcE794JXrB64fgB_MfH_m-84R2LpZSGYIU620BYF_3Puz0EZZDxGzubaDOcfFsq3rfeFxmf0C94SnL4LTF33u1-l_lVw8i-R-wudTja5G80e8ubHebP_mzfVD3twMeLO99-ZfcGtSWeT5MsXx22SHXE8gxec4xUmEM7j355gejG3remOvnzb2ZtDYvV788WIRxgmMlxf5FHDyYQIZXljsd3CeLt9BB2EGSvLp7sncqDlyXddFQkreuD8pIWHMGqX1BMHt9rfb7bfb7TfQjEro4JLqMyX51QMpc6P61PYuVYna8EbD2P4oJujPAAAA__83zhBl # # Set a relevant session variable to a non-default value and ensure it shows up @@ -74,7 +74,7 @@ SET reorder_joins_limit = 63 query T EXPLAIN (OPT, ENV) SELECT * FROM y WHERE u = 3 ---- -https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5gVwxydLhEKVzbbmH2cfI-jHLI8zOMsj6MMpjcIAOC34dt-JnTzE9HiVz4JwJsfxkzVXSP1JICb_XCHn-yfb4_xLaeGl4SaSQCTc8-_cDzf8Xzw_MDzAs-bHIFtm4VkhjDVSUvwvWPv10IbZTtETH9nF5sck2VX13viMc2-gXvB84V_vhh--33-fyMXXyXysOHXS41up8tPdLO33ez-0c3Nx7rZj3Sz-9DNv-E2pLLIq3WK46fJDrk5hRRf4RQnEc7gQz9n9FBsyxuKvfl8sfvRYg958cvrVRgnMFtf53PAyYtTyPDKYr-Bq3T9DHr48TucYujgEhZL5DiOgzSjEnoED_f3D_fvHu7fAVNSm5YKaQI48wO4OVuAA2eLW_RXAAAA__8JxwUg # Make sure it shows up correctly even if it matches the cluster setting. statement ok @@ -84,7 +84,7 @@ SET CLUSTER SETTING sql.defaults.reorder_joins_limit = 63 query T EXPLAIN (OPT, ENV) SELECT * FROM y WHERE u = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zYUvq6e4sA3TYY4leNhCBz0wnXVzVvqFLbatSgKgpaOZC4UyZKUamcY0IfIE-ZJBlJK4mCWlWBoLoKIOd_h-fnOd9jvwwfUhkkxgolMLrWkyer1K8A1JsuS8RQ1WDQWqtoqCPp9oJzLb0RpVFQjoYZIZYniVMCKGrArhBQzWnILFeUljkBmmcMl0lhiEioM-cbsijRWJJGcGHaFHfCUukg2vNVuurg4grevP3njxjcTdq_v021jq6kwNLFMCqI0k5rZTRtQSF1Q3ob-WlLO7IbIjBjUFUtaA9CYl5zqNkcaaUqk4K1x3BZnB7Y0SDLpmoXaOzJdTpjGxPejLATVTa9Q0CXHtBNral5kJefEOkiN34dbRLEDWvOVw0t3cgZwn8ytJS2tdFfUgRBWKM4SZolB7sLNpCalcuxovUrsgm-XyvlYUpusiLHUYoHCtgf-wJswqC3JqLFEUbt6FKgouWXK_SFTlrGEuhiMI4uvW0elGydXLL-iOflLsq65w7VydaIiJSwXUiMR0pKKGeb81N02h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rB5LatQgCgqKolatEpiLlWRsG9CHyKnuBPUqeZKDcOh6mpNhPfWFAR98Pv6OPjgOveauFkgFEir1vFWXvnj8DvuWs6ERd8hYM1wY2OxRCjgMZzqGkhhZUcziHqQVMl2gYC230hxrOQVXVEsBxoOQV7WoDG1p3PADaGTVAhSz5lrScqabhsqRGKKkJl7SoefmIgJIDveWqLXlLflJCalKLRhg4h6eLUc4ZGjjR6lWW49QGyOPkBegPtcvasiBCGt5KWrvGupNW_Uy0oUZoI5h2qSaqIkY0Q1rH_-N3PR21cXxPP2j0Cavd-x1NVVWNK-239KjS-A6mTxfjomcPKtqw2rWmDTWCEabqmjP7Rdz7DzKtaK35uLRpO_5v1Bsh7aZ3O9fW5Mm4wRPP-4J-pVrOqDb6_zuy7rXhDRlKoYkNsJv_AwMUpTjMMeThsxUerpJ70xW1YO4WZuiIQpzkZ5Csc0herVZzdFR8muyeonWS5WkYJzlsyc173sNlGr8M07fwPX4LMwphFh3P0VGcPMdvYEsKIsotzIphjo6XCIUrm23MPk6-w1EOWR7mcZbHUQbTKwQA8Ovwb38TuvmRaPELnwTgze_HTNVdI_UkgKv9cIef7J-vD_Etp4aXhJpJAJNTzz9zPN_xfPD8wPMCz5scgO39EJIZwlQnLcH3Dr3fCW2U7RAx_Y092OSQLLu63hMPafZO7wVPF_7pYnj32_y_Ri6-SuThhF8vNbqeLh_pZm-72f2tm5uHutmPdLP73M2_4DakssiLdYrjF8kOuTmGFF_gFCcRzuBzP2f0vtiWNxR78-Vi96PFHvLiN5erME5gtr7M54CT18eQ4ZXFfgMX6fol9PDDtzjF0ME5LJbIcRwHaUYl9Ajubm_vbj_e3X4EpqQ2LRXSBHDiB3B1sgAHThbX6M8AAAD__2aAH4o= statement ok SET enable_zigzag_join = true @@ -92,7 +92,7 @@ SET enable_zigzag_join = true query T EXPLAIN (OPT, ENV) SELECT * FROM y WHERE u = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zYUvq6e4sA3TYY4leNhCB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b-HEYV5ujgco4MofonfwYbkRBQbGOVujg5nCM2XNluffRT_gBcZpNk8i9IsWqQwvEAAAL-6f_sb0PUV0eKGD0Lwx_djpqq2lnoQwsVuuMUPds-X-_iGU8MLQs0ghMGxH5x4fuD5AfhB6Puh7w_2wPZ-CMkMYaqVlhD4-94fhDbKdoiY7toebLBPlm1V7Yj7NHund4LH0-B46t79Nv6vkfMniexO-HSp0eVw9kg3O9vN9m_dXD_Uza6nm-3Xbv4FtyalRZ6tEhy9irfI9SEk-AwnOF7gFL72c0Tvi215rtjrbxe76y22y4vfnS_nUQyj1Xk2Bhy_PYQULy32OzhLVq-hg5--xwmGFk5hOkOe53lIMyqhQ3B3e3t3-_nu9jMwJbVpqJAmhKMghIujKXhwNL1EfwYAAP__6jExBw== statement ok SET optimizer_use_histograms = false @@ -100,7 +100,7 @@ SET optimizer_use_histograms = false query T EXPLAIN (OPT, ENV) SELECT * FROM y WHERE u = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zYUvq6e4sA3TYY4leNhCBz0wnXVzVvqFLbatSgKgpaOZC4UyZKUamcY0IfIE_ZJBlKK42CWlWJoLoKIOd_h-fnOd9jvwzvUhkkxgolMrrWkyerlC8A1JsuS8RQ1WDQWqtoqCPp9oJzLL0RpVFQjoYZIZYniVMCKGrArhBQzWnILFeUljkBmmcMl0lhiEioM-cLsijRWJJGcGHaDHfCUukg2vNVuurg6gdcvP3jjxjcT9qDv811jq6kwNLFMCqI0k5rZTRtQSF1Q3ob-XFLO7IbIjBjUFUtaA9CYl5zqNkcaaUqk4K1x3BVnD7Y0SDLpmoXaOzJdTpjGxPejLATVTa9Q0CXHtBNral5kJefEOkiNP4RbRLEDWvOZw3N3cgFwn8ydJS2tdFfUgRBWKM4SZolB7sLNpCalcuxovUrsg--WyvlYUpusiLHUYoHCtgf-wJswqC3JqLFEUbt6FKgouWXK_SFTlrGEuhiMI4uvW1fFGi83LL-hOflLMuGKJ_bWrukOrpUrFRUpYbmQGomQll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#eJy0VN1u2zYUvg6f4sA3cgbLkWK0CGTkwnWZTpsrB5LatQgCgpKolKtEpiTl2RkG9CHyKnuBPUqeZCDdOh6mJNhPfWGAx98Pzzkf7fvwlinNpYhgLsuPStLyw8sXwNasLDreVEyBYdrAaotCyPchwzlU1NCCagan4FmAN0WuzLXRnxo4BVnXUwDfh4rVtGsMrGjTsQhoZ6SDMkGLhpEbfnVDr8jPkgvLEr0kWdeOw0XF1kSxUrYtExU1XApNtkrVI6ZSOLq8NrzlN0yRTjPygWsjrxRt9dNMxaSqmHLX1KThLTdwCs8nvZwT5DjzxZssx6kdVx4nr0B_asalqgrChWFK0GZs3ASU_IVoQw3Xhpd6TDWRNTG8dbP1wz9-116vjR8G-kGjL1g9vt-IJ-u6X2m3k0eV-mfgPZ_0i548qGib1WNr2lLDS1LKpmGl3eX4fpVeTRvN-qWN6ti_UW-5sJPeztxu3XvWb_AsCJ7Qr6ViJdVG_39X1httWEtcKDSxDWzr_8AAzVM8yzHksxcL7B7u-LorGl6O1zBEBxTiJD-BZJlD8maxGKGD4ktle5ovkyxPZ3GSw5pcf2QbOE_j17P0PfyI38OQwiybH47QQZy8xO9gTQrCqzUMC1dHh1OEZgvbW599nPyA5zlk-SyPszyeZ-BdIACAX923_Qzo6opofsMGEQSj-3Ipm64VehDBxa64xQ9258t9vGLUsIpQM4hgcByEJ34Q-kEIQRgFQRQEgz2wfR9clIaUshOWEAb73u5PwmaImM21vdhgnyy6ptkR92n2Te8Ejyfh8cT99tvov7ZcfJOW3Q2_Xdfo0ps-ks2NzWb3t2yuHsrmpieb3dds_gW3IrVFni1THL9KtsjVIaT4DKc4meMMvuZzSO-DbXku2Kung73pDbbrF787X8ziBIbL83wEOHl7CBleWOx3cJYuX8MGfvoepxg6OIXJFPm-7yNdUgEbBHe3t3e3n-9uP0MphTaKcmEiOAojuDiagA9Hk0v0ZwAAAP__FoxFUg== statement ok SET optimizer_use_multicol_stats = false @@ -108,7 +108,7 @@ SET optimizer_use_multicol_stats = false query T EXPLAIN (OPT, ENV) SELECT * FROM y WHERE u = 3 ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zgTva6eYuCbJh_iVI4_LAIHvXBddde7qVPYardFURC0NJK5oUiWpFQ7iwX6EHnCPsmClOI4qGWlWDQXQcTMGc7PmTPs9-EdasOkGMFEJtda0mT18gXgGpNlyXiKGiwaC1VtFQT9PlDO5ReiNCqqkVBDpLJEcSpgRQ3YFUKKGS25hYryEkcgs8zhEmksMQkVhnxhdkUaK5JITgy7wQ54Sl0kG95qN11cncDrlx-8ceObCXvQ9_musdVUGJpYJgVRmknN7KYNKKQuKG9Dfy4pZ3ZDZEYM6oolrQFozEtOdZsjjTQlUvDWOO6KswdbGiSZdM1C7R2ZLidMY-L7URaC6qZXKOiSY9qJNTUvspJzYh2kxh_CLaLYAa35zOG5O7kAuE_mzpKWVror6kAIKxRnCbPEIHfhZlKTUjl2tF4l9sF3S-V8LKlNVsRYarFAYdsDf-BNGNSWZNRYoqhdPQpUlNwy5f6QKctYQl0MxpHF162rYo2XG5bf0Jz8JZlwxRN7a9d0B9fKlYqKlLBcSI1ESEsqZpjzVDfcECZIIlUX1Vjq835QP4PGyQOxrEBZ2jYP4Rb_QwBhUVeUHxx-JY3NNRoH4FTnWBPRUZBo-aW1m4Mw9JdwmTQjqywr2A2mRFFtmUsPU8JEimvv7XCHuUyuH5WUcNFJnaLGlHBqWq2bqrt59iQnGleyQJdU52j6kJw6G8VZrb2Es4K1XnYW_v-8wfgiaEKV4pudWioUlNsNsZJUTNuSNsPepS33HmtZ0phQc3DIHNUfolbMWJlrWpgDarEX6SfO7xlLbQf6u2B3R8XzoDNZlROr8-LUsIJx6tYIsSuNZiV5a7PC06GHasxQEy7ldan8cBuvTtl156VaKpo7hjChSluTi4m8S040esvmrpoez-GX4d76eHaYz5wYmmHDyK7AtpL6qMFwS56JnNz3wL8bFGpb6qWXyh_Eu9XkeqdLjkRpuaRLxg-s9hY3mopUFsRg-8DVSFbgjRStSv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N-qVN27F_o95waSe9nbnduv-k3-BJGH5Bv1Yto0Qb_f9dWW-0YQ12odDYNrCtf4WBN8_QrEBQzJ4tkHv24-uuFJyO1zD0DggkaXEC6bKA9NViMfIOyk-V7Wm-TPMimyVpAWt8_Z5t4DxLXs6yt_AjegtDArN8fjjyDpL0OXoDa1xiXq1hWLq6dzj1vNnC9tZnn6Q_oHkBeTErkrxI5jn4Fx4AwK_u234GZHWFNb9hgxjC0X2ZKtE1Ug9iuNgVt_jB7ny5j28ZMazCxAxiGByH0UkQRkEYQRjFYRiH4WAPbN8Hl9RgqjppCVG47-3-YmyGsNlc24sN9smyE2JH3KfZN70TPJ5ExxP322-j_9py-U1adjf8dl17l_70kWxubDa7v2Vz9VA2Nz3Z7D5n8y-4Fa4t8myZoeRFukWuDiFDZyhD6Rzl8DmfQ3IfbMtzwV59Odib3mC7ftGb88UsSWG4PC9GgNLXh5CjhcV-B2fZ8iVs4KfvUYagg1OYTL0gCAJPUyJh48Hd7e3d7ce7249AldSmJVyaGI6iGC6OJhDA0eTS-zMAAP__FudbUw== statement ok RESET reorder_joins_limit @@ -132,7 +132,7 @@ CREATE SEQUENCE seq query T EXPLAIN (OPT, ENV) SELECT * FROM seq ---- -https://cockroachdb.github.io/text/decode.html#eJyUVk1PI0kMvedX1HF3NUEBZgZ20BzYTK-EBGEWApo9WU63u-Oluqriqgofv35V1ZkhSHQabhH4Pbvs5-cej9UtiWdrvqipLe_EYrn89peiByoXkXVFogL5oNZd1Gg0HivU2t6DE3IoBOjBugBOo1FL9CosSVVUY9RBrVFH-qJsXSdcaX0AX6LxcM9hCZsoKK0Gz080AK8wVfKoe-POri8_qItv_-bgDTebsJP7eDs4CBqPZWBrwAlb4fDYBzRWWtR96FVEzeERbA2eZM1lbwFCTdQofURCWIE1ureOn815BRs9QW3TsEgykR8iYaEyzyO2BmUzKzK40FQNYn2nizpqDSFBOvwu3HUxT8DgV1p9TX85Uer5MT8jMQabUnSFALdOc8kBPOlUbm0Fokvq6E1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cF--BziZTvjoJbQN6K00Worvw7qugIIOmoBVlkoSrRdBNl5YNf3yntNeGDQf0qNEvLWUPHaWurvtJv1t6ktTfQTod90PnjxJjWMqiaSODVkI5Y1DFi2QPB0lraQj70cG3-C_0RtvY9KVziiaTfoPJYPAHfu08KkmB_t8n0zcK2IjupyARA1zmf2GQ5Du-Kjns-YcDL3IOX9qT0SojPMN2XRxXmwOHIWxXt5fH16PReDwbDcbT-eTVbDaZD2awLvId3_KihCHsy9WuhOEiSfjtzWa1LuDZ9U35EnhxfA57vuF5CS_g3e56C4TnRcIYYwnhuUWrkBHG4uOb5GcAAAD__9nMSQE= # # Test views. @@ -144,7 +144,7 @@ CREATE VIEW v AS SELECT a, b, u, v FROM x, y WHERE b = 3 query T EXPLAIN (OPT, ENV) SELECT * FROM v ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u27gSvo6eYuCbxgd2IscHB4GDAsd11V3vpk5hq38oCoKSRjY3FKmSlGpnsUCxz5DLfbo8yYKUnDjbyEqwaC4Cm55vfr_5yH4f3qHSTIoRTGR8qSSNVy9fAK4xjgrGE1RgUBsoKyvP6_eBci6_klxhThUSqonMDck5FbCiGswKIcGUFtxASXmBI5BpanGx1IbomApNvjKzIrUViSUnml1hCzyhNpMNb7SbLi568PrlR2dc-2bC7PV9umtsFBWaxoZJQXLFpGJm0wQUUmWUN6G_FJQzsyEyJRpVyeLGBBQuC05VkyOFNCFS8MY8ts15AFtoJKm0w0LlHOk2J0xh7OZRZIKqelYoaMQxacXqihdpwTkxFlLh9-EWQWiBRn_h8NyenAHcFbO1pIWRNkSVCGFZzlnMDNHIbbqpVKTILTsaQ4mH4Lutsj4iauIV0YYazFCY5sTveRMalSEp1Ybk1KweBcoKblhuP8iEpSymNgdtyeL61tLp2skVW17RJflNsra9w3Vu-0RFQthSSIVESENKppn1U01bEyZILPM2nrHEFX2veRq11QZiWIayME0e_Fv8kwDCoCop37v5udRmqVBbAKdqiRULLf-Ikl8bRznwfReEy7je19ywjF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test tables in user-defined schemas. @@ -157,7 +157,7 @@ CREATE TABLE s.t (a int primary key) query T EXPLAIN (OPT, ENV) SELECT * FROM s.t; ---- -https://cockroachdb.github.io/text/decode.html#eJyUVlFv20YMfq5-xb21HeogW4ehaNAH1_UAb44T2GqxYBgIWqLkW053Fx7lxPn1w53cxhkiK3kzDH4feeTHjxqN1DfioJ39qCauuGaHxebLZ0V3VKxbbUpiJRREbbuoLBuNFBrjbsEzeWQCDOC8gDdo1QaDkg2pkipsjagtmpY-KldVEVe4IBAKtAFutWxgHwWFMxD0PQ3AS4yV7Exv3Gx18U6df7lKwXtubeUo94fDYGG0AQvRzoJn7VjLrg9oHTdo-tA3LRotO3AVBOKtLnoLYKpbg9xHxIQlOGt66_jenCewbSCoXBwWcSIKQySaqUjzaBuLvJ8VWVwbKgexodNF1RoDEiEd_hhuNc0jUMKNUZ_iP2dKPTzmeyS24mKKrhDQjTe60AKBTCy3cgytj-roTWWfgh-2KnKsUYoNBEGhhqz0F_6IzQZigQqDgEfZPAvUtEa0jz9cqStdYKwhRLGkvg10ek9yr-t7rOFfp4f2ju587BPaEnRtHRNYJ7DVQUeebtoBtIXC-SGd6TI9-lHzAoXoDSC6IddKH8PpD_yLAFaIt2iObr53QWqmEAEGuaZOhVF_wO62d5Q_n56mJMYV-331oht9TyV4ZNHxeVSCtiXdJbbj4zWuuH7Wo2ysznFJTCUYDL3R-67HZU4KB6aNayg-anAvU0nRmoM3ujNeMLrRvcl-Of31wx6TmsCA3pvdQS89WTSyA3Gw1Swt7jd9yFgeGDtPYiowDG3YY9BGB3E1Y_MiVNq0dF8EX5bvcEXS_Acf6WsQrpuToBttMN4OkA1T2DjTO6TTk_cJylQRg3HuuvVppUOypOp6MCk7j3VUhra-lU5U2tZDrsuUIve5Oll8Ur-9f9KAkyrCjYGAFe2VOFTYDx991kLEy65tDQ8zSB8LnlhaXid_fCE-3qM4O24NgWe3xrU2R-55Dw2jLV0DgfoXrUPqhu6d7XWor_kkhR3Y5nP60tq1a23Z-REaQ2b4qCZY4WwQRh3ty7po7dukiwMve-Zh31Ihjo99ntksmyyn43yq8vHn-TR18SSciHqTvUI1W-Qf1OIiV4uv8_m77NXkYrHKl-PZIlcC_pp26nI5Ox8vr9Sf0yv1BtV4NXmbvT3LsvE8ny7_zzlb_DGd5GqVj_PZKp9NVur13_-8Psuy6V-X8_Fsod5cXObv1HTx7a1aTecx9if1-_LiXIUTOctGo9EoS04u2X8BAAD___JQ7cY= +https://cockroachdb.github.io/text/decode.html#eJysk9Fq20wQha-zTzF3in-ywiEkmBhfKPrVolaRjbQJDaUsa2lEt5G0zc44TR6sL9AnK5JLA0VJaentcuY7c85IUsI1erKuP4fYVbfemerj_xeAD1htd7at0QMjMdzvVUJICWWioDZstoYQVhAMgmApxmdLTHctrMA1zRJASqixMbuW4d60OzwHs2M3Sm1f44P2WLmuw742bF1PGnuzbbF-AeD6cdyj8zV6_cnZnnRrO8uwgrOTyZmFGGfi7KpUSTEEUGn-GuiuDStfb7XtGX1v2pAHd-3dF01s2BLbikJD2jWabTemlcffvlIwaSOP5_Ss0Q8thU8dBa5ppkk_W3qRNN1BcHYyDV08SxzCUjiYdoZtpSvXtlgNFwmfDhI0piWcRrPf4d_QO9sPTe87p8HkdNrgdD7_Db9xHitDTP9uZXokxk6PHwXpIcD-_Q8MRFwkkUpARRdZMv5KIYUMh-LAQJqrBeRrBflVlh2Jg3idl6qI0lwB68-3-AibIr2Miht4m9zAoYGojGdithQiyoaFf2Gm-ZskVlCqSKWlSuMSgvcfgqUQybtNFqU5HK436giS_HoGZZIN2v_gVbG-BAp5KaSUUlBlemDxPQAA__-R_U-F # # Test default_transaction_quality_of_service settings. @@ -169,7 +169,7 @@ SET default_transaction_quality_of_service=background query T EXPLAIN (OPT, ENV) VALUES(1); ---- -https://cockroachdb.github.io/text/decode.html#eJyUVs1OHEkMvs9T1BEkJoLNahUl4pBNOETKJpEgaPdkebrdPV6qy4XLPfyc8hA8IU8SVXUnDBI9DbfRyN9nl_35c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Aif36hCGC4Qe0Y3REjapSyoUiYM3KTXQ7hq_QCPYpPUlBum42SokW3xHvfEz9RKdhQZBv8JVwH8xADmk___wf0SKbqrKspghAL7I6pLFMKVuUaahSskAnmkKdAPsv6Y2qwc6Ilomc0YoPX2w6dlScdGs0Ud9akUoXm4T6GztczAKV-FmGHrqNLiHTfOYxHpmXhrYM5hKYZTGMnoY9aX9OjjmRC25KvMe2zJo-Vo_oNQPB9PVKINUX9OVjP2tnWCszh_HSwc5H1nevF3WpdfkhS1jfLd8BbV5hYV9p6oejRFZLWdQxfNAuKZbGGC-TkQ2zbG1TTb185H5xR0wm_OvQjy8WLozw0zTDpl6U3ScMO8vPTYejFq8R0WS7SaItijTbBOepfRPHyQ_IGHdMwWmJHf0NvrU-mj845jZwND5xNJr_hNyGSQRb-d5_MTyzU6v5RsE4XOJ7_wUBWfrxdXN0sYfT-dn0C5XIzhs3V4q5cwWg6nmVKKZX1Bc7gsN8f9s-H_TOMpifj7HsAAAD__yAgUKM= statement ok SET default_transaction_quality_of_service=critical @@ -177,7 +177,7 @@ SET default_transaction_quality_of_service=critical query T EXPLAIN (OPT, ENV) VALUES(1); ---- -https://cockroachdb.github.io/text/decode.html#eJyUVs1OHEkMvs9T1BEkJoLNahUl4pBNOETKJpEgaPdkebrdPV6qy4XLPfyc8hA8IU8SVXUnDBI9DbfRyN9nl_35cy-X7pw0sYS37oNUFypYrT_-7eiaqlXPviZ1RsncZohaLJZLh97LFUSliEqACSQaRI_BrTE5W5OrqcHem9ug7-mtk6bJuEqSQaowJLhiW8MYBZV4SHxLM_AacyU3fjLu0-nXA_fPx_9K8MjNwXZyv9kONsWQsDKWAFFZlO1mChhEO_SL05OzJ-GXPXq2G5AGEumGK3LHrlI2rtC_c-4h6y9Cpbb3qFP1KGENEvxkQb-69AS2TwSN5KmRFqI0R8JKVRlM3wXUcWgUcOWpnsWmQSBN7z1Yhgz4XbjSRk6WLr07zv882SLsTXKKoRDgLnqu2CCRz-U2otDHLJPJVOEp-HarMscKrVpDMjTqKNh04Y_YQiI1aDAZRLT1s0Bd741j_iE1N1xhriFl0ZS-zXR6JLnl9hZb-F94bgHpOuY-YaiB2yBKEMRgw4kzzzDtBBygkjinM67Lox81L1HKJgHGHUlvUwyHv_EvAgQj3aDfaQFRkrVKKQM8akuDCrP-QOVqcpRHh4cliZdq3Nto3PEt1RBRjfPzqAYONV0Xtt3j9VJdPOtRIVcnWpNSDR7TZPTY9bzMReGgtJaO8qNm97KUlD06Rc-DA4PnjieT_XH455sRU5qggDH6m61eRgro7QZMYMNqPY6bPmcsD4yDJylVmOY27DFozcmkVexehCqbVg6N4cvyba9Imf_sI2MLpm33KnHHHvMRAVsrpbX4ySEdvnpdoEoNKXiRiz6WlU7FkpqL2aQqEdusDA6xt0FUHNo511UqkWOuQRbH7q_XTxpwUUW69JCwoVGJc4X99tFnLUQ-8RxaeJhB-WqIpNbrqvjjC_H5HuXZae8JosoKV-x3HPYJGsVQSweJphdtQHJHtxImHer72YcStmWbz-lLH1bSh3rwI_Se_PxRLbBKQjJFzvYVJFv7puhiy8ueedg3VJnoru-0sFic_Pvt8_tPX9ze129nB-7ky_m-O3__-fvJqds72n-3WC6Xy0UJTwt3f3d3f_fj_u6H2zs62F_8DAAA___xENJq +https://cockroachdb.github.io/text/decode.html#eJyskkFqGzEUhvc6xduNDdFgExJCjBdpakrAuKF2THfiWfOmVauRsN4bN9nlEL5KL9Cj-CRF47bZTFJashX___2jb6Q1rCmxi-ESrqP9miLaz2_fAN2T3bTOV5RAiAV2x5RSWsNytoIKBTfIBFMocqCYqO6Yamy9GEkYGK24GMy2Re_kwcTaMKWds7lkkxNn0U8AtP5dgx36li4h0afWYzoSHQtvPUwh1nVvGluJXdSFiu5NIhubhkKFeZ0NBdx4ql4AxNDVE8VUUTJfogtsvGucwBTOT3s7F6rrXM_vlqvZh6xkdbN4B7z1pU3VxrgglAL6UvK6SfGbYUFxLM5yiZxtiGs6f3r84zsXvTN6POJnh35luXxyVMS67if9sfQiqd9BcX7aD714lpgvy2UebVCcNTZ6T917KJ9-SFGjZ-pHS2rpf-iNC9n00TnnkbP-gbPR6C_8OiayyMKv98n8wEKN6R4Fm3yB4_k_DKjZx9v51c0CBu9vVycwW6yHsL6a382WMBgPJ0prrVVXYAWH_f6wfzzsH2EwPhmqnwEAAP__6QxPzg== # # Test recursive table references from foreign keys. @@ -194,17 +194,17 @@ CREATE TABLE z ( query T EXPLAIN (OPT, ENV) SELECT * FROM z; ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vt1u2zgTva6egvBNkw9xICcfFoGDXriuuvBu6hS2WrQoCmIsjWSuKZLlj2J7se--IOUkDmpZCRbNRRAxc4bzc-YM-33yGbVhUgzJWGYrLSFbvntLcI3ZwjGeoyYWjSV1YxVF_T4BzuUdVRoVaKRgqFSWKg6CLMEQu0SSYwGOW1IDdzgksig8LpPGUpOBMPSO2SXdWdFMcmrYFjvgOfhINrzVbjK_PSMf3n0NxjvfTNijvq_2ja0GYSCzTAqqNJOa2U0bUEhdAY_mSXoQ_sMBZ3ZDZUEN6pplSN6QTDPLMuDXhDzeeu9QY-k46LZ4NEJOpeCtAd1X6QDWGaSF9F1DHRyZLidMYxYa4yoBetc0FLDgmHdiTUOQwnFOrYc0-GO4UEZmrPnByRt_crBE4Kz0VzSBUFYpzjJmqUHuwy2kpk55mrReJQ7B90vlfSzAZktqLFisUNj2wJ94Ewa1pQUYSxXY5bNAleOWKf-HzFnBMvAxGE-aULeOSu-cbFm5hZL-JVnXAOJa-TqByCkrhdRIhbS0ZoZ5P023DWWCZlJ18YzlIeknxTNovEhQyyqUzrZ5iB_wLwIIi7oGflQClDS21Gg8gIMusWGh5x_V8q61lYM4Dpdwme3mVllWsS3mVIG2zKeHOWUix3Xwdry9XGarZyUlfHRS56gxpxxMq_Wu6n6YA8OpxqWs0CfVOZchJK_RRnHWKDDlrGKtl13E_7_aYUIRNAWl-GavlgoFcLuhVtKaaetgN-ldwvLosdEkjRmYrgl7CloyY2WpoXoRKkxaW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jP_60_Y7bYJxaE8afcHa0WFHfV2W3Ur7LZ1V6t5B__l1t-jNSUUf1o686Zo6wQjTUvK2D6PDH9IvqbS8W9qZiv8b9bVQftO7nVtv8qzb4FkYfke_1IYzap39_65sG-v4mrSlsMQH2M3_gQGaJ3iWYchmLxa4fZyjTZVLwUY1DNAFhSjObiBeZhC_WSyG6CL_Mtmd5ss4zZJZFGdQk82KN3CfRK9nyXv4Bb-HAYVZOr8coosofonfQU1yIooaBnk7R5dThGYLn63LPop_xvMM0myWRWkWzVPof0AAAL-33_7To9tPxIpH3ptAODyMmZbVWtneBD7shzt8b3_-eIw3nDpeEOp6E-hdheObIBwH4RjC8SQMJ2HYOwL79yEUc4TpSnnCODz2_iys075DxDUbf7HeMVlVUu6JxzT_pveCV9fjq-v2tz-G_zVy_kMitzf8canRx_70TDcb383qm25uT3Wz6ehm9dTNr3BbUnrk3TLB0at4h9xeQoLvcILjOU7hqZ8Deii257XF3n6_2E1nsc_nffR5N6tvAhtenor82BF5s-rIXK6-Tmt42ZW3GVTncz2ezoXf3S9mUQyD5X02BBy_vYQULzz2J7hLlq-hnqIgCAJkGVVQo78DAAD__xpFaYs= # A foreign key cycle shouldn't cause infinite recursion. statement ok @@ -213,7 +213,7 @@ ALTER TABLE y ADD CONSTRAINT fk FOREIGN KEY (v) REFERENCES z (pk); query T EXPLAIN (OPT, ENV) SELECT * FROM y; ---- -https://cockroachdb.github.io/text/decode.html#eJy0Vl1v2zoSfa5-BeGXOos4kJPFInDQB9dVF95NncJWixZFQYylkcxrimRJSrV8cf_7BSklcVDLSnDRPAQRM2e-eOYMRyPyGbVhUkzITCZbLSHZvHtLcIfJumQ8RU0sGkuqxioIRiMCnMufVGlUoJGCoVJZqjgIsgFD7AZJihmU3JIKeIkTIrPM4RJpLDUJCEN_MruhrRVNJKeG7bEHnoLLpOaddvPV3Tn58O6rN259M2FP-r4-NLYahIHEMimo0kxqZusuoJC6AB6sovgo_EcJnNmayowa1BVLkLwhiWaWJcBvCHm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0THL2JdyDDy0tI8B1OcDzFKTw-oe5V5wu8bS3weV-191V9Z2t9ylTdYqpq8VSTNSk98h_O1m2-Nj36RCCta9veanE4dK_XHPr66UOvT-eEP9zPJlEMvfl91gccv7-EFM889ie4S-ZvoR6jIAgCZBlVUKO_AwAA__9EenlR # Check that we remove histograms from statistics correctly. @@ -269,4 +269,4 @@ ALTER TABLE b INJECT STATISTICS '[ query T EXPLAIN (OPT, ENV) SELECT * FROM b ---- -https://cockroachdb.github.io/text/decode.html#eJy8VlFv2zYQfq5-BeGXpkMcOE63pQ764Dou4M21i1gtWhTFgZJO8i0UyZCUE2fYfx9IKYkDRFbysPnBsMn7jsfv7r5jv8--orGk5IhNVHppFE_X5x8Y3mCaVCQyNMyhdWxTW0VRv8-4EOoatEHNDQK3oLQDLbhka26ZWyPLMOeVcGzDRYUjpvLc41JlHdiUSwvX5NbQWEGqBFi6xQ54xn0kW9FqN1stD9mn8-_BuPFN0u31fbpr7AyXlqeOlARtSBly2zagVKbkIlpN4yfhVxUX5LagcrBoNpQie89SQ45SLs4Yezj1zqHBohLctMVjkGegpGgN6I6lJ7CVRciVzxqa4Mh2OSGDaUhMVUpumqSh5InArBNr6wLJKyHAeUiN34cLNJJ19kqw937lSYp45ZQ_og4EqNSCUnJgUfhwc2Wg0r5MWo-ST8F3qfI-Eu7SNVjHHZYoXXvgj7xJi8ZBzq0Dzd36WaCyEo60_6EyyinlPgbriybw1sF04-SWiltewF-KuhoQb7TnicsMqJDKIEjlYEOWvJ862xZIQqp0V51RFi79iDyL1osEOCpRVa7Nw-Ae_yKAdGg2XOyVAK2sKwxaDxDcFFhXoa8_MOq6NZXHg0E4RKi06VvtqKRbzEBz48hfDzMgmeFN8LY_vUKll8-6lPTRKZOhwQwEt63WDeu-mUOFg8G1KtFfqrMvQ0heo60WVCswCCqp9bDh4O1pgwkkGOBai-0OlxolF24LTsGGjKt40-ldwvLgsdYkgym3XR32GLQm61RhePkiVOi0MGgcf9l5uy0S8t95SV2AM0V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cmM5NRExrg3Le99fOP_tVxOMxoTz2DwZ9JVroseOAtV14067lp51Gu8geHk0bnrypKN7WBO50J5YTjFVQjC_D9HjhQQdEYaNW1s9sH_i3nPpmt52blzI8XjAcRz_iX-nNKPEWPPvHdncG8t67JfCYPcAW_xvBKDVJkvrDOr0rMj8yxldD43gNGpgig4aOFuvCyjXNZSXRTFDB1p94S3kZX3i0au8yp3ygQHn2ev0sqhhkPxm8LXxdno4QwerdVnVmzQva2jw9Wd2Dxeb_E26eQc_ZO9guvVNq5Xj5uV59hYa3GDe3sG08Tg6XCKUFq6KsdPm5ffZqoaqTuu8qvNVBcF7BADws_92nwm5_YgN_4lNFjCfPcJUiaGXZrKA9zvQD5rJ7veHfb5mxLIWEztZwCSJkyScJ2GcwPxkcfRikbyKjr998eoomexp3FvFJbWYqkE6XbI3_MSNVW7vsL2_dqeb7Esl6T2G_RVj_IfZIMTOMt4buP-IB3w-j2M_-WX2TCPxX2nEX9N_2Er8_7XytRL0IVgilL29KNK8hOn6op5BVl4dQpUVbqG-gdeb9RtoligMwxAZSiQ06PcAAAD__yNtCSU= diff --git a/pkg/sql/opt_exec_factory.go b/pkg/sql/opt_exec_factory.go index a0d161fa30a7..8e9957064b29 100644 --- a/pkg/sql/opt_exec_factory.go +++ b/pkg/sql/opt_exec_factory.go @@ -1226,16 +1226,20 @@ func (ef *execFactory) showEnv(plan string, envOpts exec.ExplainEnvData) (exec.N ie := ef.planner.extendedEvalCtx.ExecCfg.InternalDB.NewInternalExecutor( ef.planner.SessionData(), ) - c := makeStmtEnvCollector(ef.ctx, ie.(*InternalExecutor)) + c := makeStmtEnvCollector(ef.ctx, ef.planner, ie.(*InternalExecutor)) // Show the version of Cockroach running. if err := c.PrintVersion(&out.buf); err != nil { return nil, err } out.writef("") - // Show the values of any non-default session variables that can impact - // planning decisions. - if err := c.PrintSessionSettings(&out.buf, &ef.planner.extendedEvalCtx.Settings.SV); err != nil { + // Show the values of all non-default session variables and session + // settings. + if err := c.PrintSessionSettings(&out.buf, &ef.planner.extendedEvalCtx.Settings.SV, false /* all */); err != nil { + return nil, err + } + out.writef("") + if err := c.PrintClusterSettings(&out.buf, false /* all */); err != nil { return nil, err }