From a5e68b154f23b57a5f62b19eae524a5001d47bc8 Mon Sep 17 00:00:00 2001 From: Faizan Qazi Date: Mon, 5 Jun 2023 11:12:09 -0400 Subject: [PATCH 1/2] sql/schemachanger: enforce one transition per-statement phase as a rule Previously, we had code inside the stage builder to enforce that only a single transition was allowed per-statement phase. This would have made it hard to implement CREATE statements since we need to apply multiple transitions. To address this, this patch adds dep rules to limit the number of transitions, which will be later disabled for create statements. To help support this a new precedence type is introduced. Epic: none Release note: None merge to 0 : --- .../drop_database_multiregion_primary_region | 2 +- .../end_to_end/drop_table_multiregion | 2 +- .../drop_table_multiregion_primary_region | 2 +- .../drop_database_multiregion_primary_region | 228 ++--- .../testdata/explain/drop_table_multiregion | 134 +-- .../drop_table_multiregion_primary_region | 100 ++- .../drop_database_multiregion_primary_region | 144 ++- .../explain_verbose/drop_table_multiregion | 216 ++++- .../drop_table_multiregion_primary_region | 140 ++- .../scplan/internal/opgen/op_gen.go | 1 + .../scplan/internal/opgen/target.go | 4 + .../scplan/internal/rules/current/BUILD.bazel | 1 + .../rules/current/dep_statement_phase.go | 149 ++++ .../internal/rules/current/testdata/deprules | 824 ++++++++++++++++++ .../internal/scgraph/depedgekind_string.go | 3 + .../scplan/internal/scgraph/edge.go | 5 + .../scplan/internal/scstage/BUILD.bazel | 1 + .../scplan/internal/scstage/build.go | 67 +- pkg/sql/schemachanger/scplan/plan.go | 1 + .../scplan/testdata/alter_table_drop_column | 104 ++- .../scplan/testdata/create_function | 4 + .../scplan/testdata/create_schema | 4 + .../scplan/testdata/drop_database | 378 ++++++-- .../schemachanger/scplan/testdata/drop_index | 104 ++- .../scplan/testdata/drop_owned_by | 248 +++++- .../schemachanger/scplan/testdata/drop_schema | 290 ++++-- .../schemachanger/scplan/testdata/drop_table | 735 +++++++++++++++- .../schemachanger/scplan/testdata/drop_view | 234 ++++- .../end_to_end/create_function_in_txn | 9 +- ...op_column_create_index_separate_statements | 42 +- .../drop_index_with_materialized_view_dep | 2 +- .../drop_multiple_columns_separate_statements | 31 +- .../testdata/end_to_end/drop_table | 2 +- .../end_to_end/drop_table_udf_default | 2 +- .../create_function_in_txn.statement_2_of_2 | 52 +- ...index_separate_statements.statement_2_of_2 | 37 +- .../drop_index_with_materialized_view_dep | 121 +-- ...lumns_separate_statements.statement_2_of_2 | 45 +- .../schemachanger/testdata/explain/drop_table | 138 +-- .../testdata/explain/drop_table_udf_default | 117 +-- .../testdata/explain_verbose/create_function | 3 + .../create_function_in_txn.statement_1_of_2 | 3 + .../create_function_in_txn.statement_2_of_2 | 36 +- .../testdata/explain_verbose/create_schema | 3 + ...index_separate_statements.statement_2_of_2 | 137 ++- .../drop_index_with_materialized_view_dep | 188 +++- ...lumns_separate_statements.statement_2_of_2 | 149 +++- .../testdata/explain_verbose/drop_table | 242 ++++- .../explain_verbose/drop_table_udf_default | 192 +++- 49 files changed, 4768 insertions(+), 908 deletions(-) create mode 100644 pkg/sql/schemachanger/scplan/internal/rules/current/dep_statement_phase.go diff --git a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_database_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_database_multiregion_primary_region index adee6b9b8f6f..2cd6cedce31a 100644 --- a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_database_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_database_multiregion_primary_region @@ -30,7 +30,7 @@ write *eventpb.DropDatabase to event log: statement: DROP DATABASE ‹multi_region_test_db› CASCADE tag: DROP DATABASE user: root -## StatementPhase stage 1 of 1 with 47 MutationType ops +## StatementPhase stage 1 of 1 with 57 MutationType ops delete database namespace entry {0 0 multi_region_test_db} -> 104 delete schema namespace entry {104 0 public} -> 105 delete object namespace entry {104 105 crdb_internal_region} -> 106 diff --git a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion index 9cb957b5362f..94c5de630747 100644 --- a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion +++ b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion @@ -25,7 +25,7 @@ write *eventpb.DropTable to event log: tag: DROP TABLE user: root tableName: multi_region_test_db.public.table_regional_by_row -## StatementPhase stage 1 of 1 with 24 MutationType ops +## StatementPhase stage 1 of 1 with 38 MutationType ops delete object namespace entry {104 105 table_regional_by_row} -> 108 upsert descriptor #106 ... diff --git a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion_primary_region index eb05d6e06a21..edf9b58f010c 100644 --- a/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/end_to_end/drop_table_multiregion_primary_region @@ -26,7 +26,7 @@ write *eventpb.DropTable to event log: tag: DROP TABLE user: root tableName: multi_region_test_db.public.table_regional_by_table -## StatementPhase stage 1 of 1 with 17 MutationType ops +## StatementPhase stage 1 of 1 with 27 MutationType ops delete object namespace entry {104 105 table_regional_by_table} -> 108 upsert descriptor #106 ... diff --git a/pkg/ccl/schemachangerccl/testdata/explain/drop_database_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/explain/drop_database_multiregion_primary_region index bbf5ceed693f..ff2a48a35bfe 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain/drop_database_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/explain/drop_database_multiregion_primary_region @@ -10,60 +10,61 @@ EXPLAIN (ddl) DROP DATABASE multi_region_test_db CASCADE; Schema change plan for DROP DATABASE ‹multi_region_test_db› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 52 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "public"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Database:{DescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT DatabaseRoleSetting:{DescID: 104 (multi_region_test_db-), Name: "__placeholder_role_name__"} - │ │ ├── PUBLIC → ABSENT DatabaseRegionConfig:{DescID: 104 (multi_region_test_db-), ReferencedDescID: 106 (crdb_internal_region-)} - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 105 (public-), Name: "public", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (public-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "public"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Schema:{DescID: 105 (public-)} - │ │ ├── PUBLIC → ABSENT SchemaParent:{DescID: 105 (public-), ReferencedDescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 106 (crdb_internal_region-), Name: "crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 106 (crdb_internal_region-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "public"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "root"} - │ │ ├── PUBLIC → DROPPED EnumType:{DescID: 106 (crdb_internal_region-)} - │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east1"} - │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east2"} - │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east3"} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 106 (crdb_internal_region-), ReferencedDescID: 105 (public-)} - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 107 (_crdb_internal_region-), Name: "_crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 107 (_crdb_internal_region-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "public"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "root"} - │ │ ├── PUBLIC → DROPPED AliasType:{DescID: 107 (_crdb_internal_region-), ReferencedTypeIDs: [106 (crdb_internal_region-), 107 (_crdb_internal_region-)]} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 107 (_crdb_internal_region-), ReferencedDescID: 105 (public-)} - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_table-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_table-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public-)} - │ │ ├── PUBLIC → ABSENT TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (crdb_internal_region-)} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} - │ └── 47 Mutation operations + │ ├── 53 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "public"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Database:{DescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT DatabaseRoleSetting:{DescID: 104 (multi_region_test_db-), Name: "__placeholder_role_name__"} + │ │ ├── PUBLIC → ABSENT DatabaseRegionConfig:{DescID: 104 (multi_region_test_db-), ReferencedDescID: 106 (crdb_internal_region-)} + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 105 (public-), Name: "public", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (public-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "public"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (public-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Schema:{DescID: 105 (public-)} + │ │ ├── PUBLIC → ABSENT SchemaParent:{DescID: 105 (public-), ReferencedDescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 106 (crdb_internal_region-), Name: "crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 106 (crdb_internal_region-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "public"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "root"} + │ │ ├── PUBLIC → DROPPED EnumType:{DescID: 106 (crdb_internal_region-)} + │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east1"} + │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east2"} + │ │ ├── PUBLIC → ABSENT EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east3"} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 106 (crdb_internal_region-), ReferencedDescID: 105 (public-)} + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 107 (_crdb_internal_region-), Name: "_crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 107 (_crdb_internal_region-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "public"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "root"} + │ │ ├── PUBLIC → DROPPED AliasType:{DescID: 107 (_crdb_internal_region-), ReferencedTypeIDs: [106 (crdb_internal_region-), 107 (_crdb_internal_region-)]} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 107 (_crdb_internal_region-), ReferencedDescID: 105 (public-)} + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_table-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_table-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public-)} + │ │ ├── PUBLIC → ABSENT TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (crdb_internal_region-)} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} + │ └── 57 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":106} │ ├── NotImplementedForPublicObjects {"DescID":106,"ElementType":"scpb.EnumTypeVal..."} │ ├── NotImplementedForPublicObjects {"DescID":106,"ElementType":"scpb.EnumTypeVal..."} @@ -97,6 +98,9 @@ Schema change plan for DROP DATABASE ‹multi_region_test_db› CASCADE; │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"root"} │ ├── AssertColumnFamilyIsRemoved {"TableID":108} + │ ├── RemoveColumnNotNull {"ColumnID":1,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":108} │ ├── MarkDescriptorAsDropped {"DescriptorID":104} │ ├── DrainDescriptorName {"Namespace":{"DatabaseID":104,"DescriptorID":105,"Name":"public"}} │ ├── NotImplementedForPublicObjects {"DescID":105,"ElementType":"scpb.Owner"} @@ -106,66 +110,74 @@ Schema change plan for DROP DATABASE ‹multi_region_test_db› CASCADE; │ ├── DrainDescriptorName {"Namespace":{"DatabaseID":104,"DescriptorID":106,"Name":"crdb_internal_re...","SchemaID":105}} │ ├── DrainDescriptorName {"Namespace":{"DatabaseID":104,"DescriptorID":107,"Name":"_crdb_internal_r...","SchemaID":105}} │ ├── DrainDescriptorName {"Namespace":{"DatabaseID":104,"DescriptorID":108,"Name":"table_regional_b...","SchemaID":105}} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":108} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":108} │ ├── DrainDescriptorName {"Namespace":{"DescriptorID":104,"Name":"multi_region_tes..."}} │ ├── NotImplementedForPublicObjects {"DescID":104,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":104,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":104,"User":"public"} - │ └── RemoveUserPrivileges {"DescriptorID":104,"User":"root"} + │ ├── RemoveUserPrivileges {"DescriptorID":104,"User":"root"} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"TableID":108} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":108} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":108} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 52 elements transitioning toward ABSENT - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "public"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Database:{DescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC DatabaseRoleSetting:{DescID: 104 (multi_region_test_db-), Name: "__placeholder_role_name__"} - │ │ │ ├── ABSENT → PUBLIC DatabaseRegionConfig:{DescID: 104 (multi_region_test_db-), ReferencedDescID: 106 (crdb_internal_region-)} - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 105 (public-), Name: "public", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 105 (public-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "public"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Schema:{DescID: 105 (public-)} - │ │ │ ├── ABSENT → PUBLIC SchemaParent:{DescID: 105 (public-), ReferencedDescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 106 (crdb_internal_region-), Name: "crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 106 (crdb_internal_region-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "public"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC EnumType:{DescID: 106 (crdb_internal_region-)} - │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east1"} - │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east2"} - │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east3"} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 106 (crdb_internal_region-), ReferencedDescID: 105 (public-)} - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 107 (_crdb_internal_region-), Name: "_crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 107 (_crdb_internal_region-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "public"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC AliasType:{DescID: 107 (_crdb_internal_region-), ReferencedTypeIDs: [106 (crdb_internal_region-), 107 (_crdb_internal_region-)]} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 107 (_crdb_internal_region-), ReferencedDescID: 105 (public-)} - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db-)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_table-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_table-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public-)} - │ │ │ ├── ABSENT → PUBLIC TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (crdb_internal_region-)} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} + │ │ ├── 53 elements transitioning toward ABSENT + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "public"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 104 (multi_region_test_db-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Database:{DescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC DatabaseRoleSetting:{DescID: 104 (multi_region_test_db-), Name: "__placeholder_role_name__"} + │ │ │ ├── ABSENT → PUBLIC DatabaseRegionConfig:{DescID: 104 (multi_region_test_db-), ReferencedDescID: 106 (crdb_internal_region-)} + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 105 (public-), Name: "public", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 105 (public-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "public"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (public-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Schema:{DescID: 105 (public-)} + │ │ │ ├── ABSENT → PUBLIC SchemaParent:{DescID: 105 (public-), ReferencedDescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 106 (crdb_internal_region-), Name: "crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 106 (crdb_internal_region-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "public"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (crdb_internal_region-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC EnumType:{DescID: 106 (crdb_internal_region-)} + │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east1"} + │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east2"} + │ │ │ ├── ABSENT → PUBLIC EnumTypeValue:{DescID: 106 (crdb_internal_region-), Name: "us-east3"} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 106 (crdb_internal_region-), ReferencedDescID: 105 (public-)} + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 107 (_crdb_internal_region-), Name: "_crdb_internal_region", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 107 (_crdb_internal_region-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "public"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (_crdb_internal_region-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC AliasType:{DescID: 107 (_crdb_internal_region-), ReferencedTypeIDs: [106 (crdb_internal_region-), 107 (_crdb_internal_region-)]} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 107 (_crdb_internal_region-), ReferencedDescID: 105 (public-)} + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db-)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_table-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_table-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public-)} + │ │ │ ├── ABSENT → PUBLIC TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (crdb_internal_region-)} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion b/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion index 2fe4841cea2f..2044acf55644 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion +++ b/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion @@ -10,35 +10,37 @@ EXPLAIN (ddl) DROP TABLE multi_region_test_db.public.table_regional_by_row; Schema change plan for DROP TABLE ‹multi_region_test_db›.‹public›.‹table_regional_by_row›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 27 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_row-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_row-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_row-), ReferencedDescID: 105 (public)} - │ │ ├── PUBLIC → ABSENT TablePartitioning:{DescID: 108 (table_regional_by_row-)} - │ │ ├── PUBLIC → ABSENT TableLocalityRegionalByRow:{DescID: 108 (table_regional_by_row-)} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_row-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnFamilyID: 0 (primary-), ColumnID: 2 (crdb_region-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} - │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} - │ │ ├── PUBLIC → ABSENT IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row_pkey", IndexID: 1 (table_regional_by_row_pkey-)} - │ └── 24 Mutation operations + │ ├── 29 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_row-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_row-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_row-), ReferencedDescID: 105 (public)} + │ │ ├── PUBLIC → ABSENT TablePartitioning:{DescID: 108 (table_regional_by_row-)} + │ │ ├── PUBLIC → ABSENT TableLocalityRegionalByRow:{DescID: 108 (table_regional_by_row-)} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_row-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnFamilyID: 0 (primary-), ColumnID: 2 (crdb_region-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} + │ │ ├── PUBLIC → ABSENT IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row_pkey", IndexID: 1 (table_regional_by_row_pkey-)} + │ └── 38 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":108} │ ├── RemoveObjectParent {"ObjectID":108,"ParentSchemaID":105} │ ├── NotImplementedForPublicObjects {"DescID":108,"ElementType":"scpb.TablePartit..."} @@ -60,39 +62,55 @@ Schema change plan for DROP TABLE ‹multi_region_test_db›.‹public›.‹tab │ ├── NotImplementedForPublicObjects {"DescID":108,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"root"} + │ ├── RemoveColumnNotNull {"ColumnID":1,"TableID":108} │ ├── RemoveDroppedColumnType {"ColumnID":2,"TableID":108} │ ├── UpdateTableBackReferencesInTypes {"BackReferencedTableID":108} - │ └── AssertColumnFamilyIsRemoved {"TableID":108} + │ ├── RemoveColumnNotNull {"ColumnID":2,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":108} + │ ├── AssertColumnFamilyIsRemoved {"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":108} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":108} + │ ├── RemoveColumnFromIndex {"ColumnID":2,"IndexID":1,"TableID":108} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"Ordinal":1,"TableID":108} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":108} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":2,"TableID":108} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 27 elements transitioning toward ABSENT - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_row-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_row-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_row-), ReferencedDescID: 105 (public)} - │ │ │ ├── ABSENT → PUBLIC TablePartitioning:{DescID: 108 (table_regional_by_row-)} - │ │ │ ├── ABSENT → PUBLIC TableLocalityRegionalByRow:{DescID: 108 (table_regional_by_row-)} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_row-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnFamilyID: 0 (primary-), ColumnID: 2 (crdb_region-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} - │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} - │ │ │ ├── ABSENT → PUBLIC IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row_pkey", IndexID: 1 (table_regional_by_row_pkey-)} + │ │ ├── 29 elements transitioning toward ABSENT + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_row-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_row-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_row-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_row-), ReferencedDescID: 105 (public)} + │ │ │ ├── ABSENT → PUBLIC TablePartitioning:{DescID: 108 (table_regional_by_row-)} + │ │ │ ├── ABSENT → PUBLIC TableLocalityRegionalByRow:{DescID: 108 (table_regional_by_row-)} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_row-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnFamilyID: 0 (primary-), ColumnID: 2 (crdb_region-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} + │ │ │ ├── ABSENT → PUBLIC IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row_pkey", IndexID: 1 (table_regional_by_row_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion_primary_region index 5befe80d867d..d0cfe123014c 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/explain/drop_table_multiregion_primary_region @@ -10,28 +10,29 @@ EXPLAIN (ddl) DROP TABLE multi_region_test_db.public.table_regional_by_table CAS Schema change plan for DROP TABLE ‹multi_region_test_db›.‹public›.‹table_regional_by_table› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 20 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_table-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_table-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public)} - │ │ ├── PUBLIC → ABSENT TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (#106)} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} - │ └── 17 Mutation operations + │ ├── 21 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 108 (table_regional_by_table-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Table:{DescID: 108 (table_regional_by_table-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public)} + │ │ ├── PUBLIC → ABSENT TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (#106)} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} + │ └── 27 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":108} │ ├── RemoveObjectParent {"ObjectID":108,"ParentSchemaID":105} │ ├── RemoveBackReferenceInTypes {"BackReferencedDescriptorID":108} @@ -48,30 +49,41 @@ Schema change plan for DROP TABLE ‹multi_region_test_db›.‹public›.‹tab │ ├── NotImplementedForPublicObjects {"DescID":108,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":108,"User":"root"} - │ └── AssertColumnFamilyIsRemoved {"TableID":108} + │ ├── AssertColumnFamilyIsRemoved {"TableID":108} + │ ├── RemoveColumnNotNull {"ColumnID":1,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":108} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":108} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":108} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":108} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"TableID":108} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":108} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":108} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 20 elements transitioning toward ABSENT - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_table-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_table-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public)} - │ │ │ ├── ABSENT → PUBLIC TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (#106)} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} + │ │ ├── 21 elements transitioning toward ABSENT + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 108 (table_regional_by_table-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 108 (table_regional_by_table-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 108 (table_regional_by_table-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 105 (public)} + │ │ │ ├── ABSENT → PUBLIC TableLocalitySecondaryRegion:{DescID: 108 (table_regional_by_table-), ReferencedDescID: 106 (#106)} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 108 (table_regional_by_table-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_database_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_database_multiregion_primary_region index 8c9652aae122..5fe3d5d39d89 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_database_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_database_multiregion_primary_region @@ -13,7 +13,7 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 52 elements transitioning toward ABSENT +│ ├── • 53 elements transitioning toward ABSENT │ │ │ │ │ ├── • Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} │ │ │ │ PUBLIC → ABSENT @@ -284,10 +284,25 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} │ │ │ │ PUBLIC → ABSENT @@ -308,16 +323,25 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -338,10 +362,16 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -361,11 +391,29 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ └── • IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ │ PUBLIC → ABSENT @@ -376,7 +424,7 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 47 Mutation operations +│ └── • 57 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 106 @@ -511,6 +559,18 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ ├── • AssertColumnFamilyIsRemoved │ │ TableID: 108 │ │ +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 104 │ │ @@ -557,6 +617,22 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ Name: table_regional_by_table │ │ SchemaID: 105 │ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ │ ├── • DrainDescriptorName │ │ Namespace: │ │ DescriptorID: 104 @@ -574,15 +650,28 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ DescriptorID: 104 │ │ User: public │ │ -│ └── • RemoveUserPrivileges -│ DescriptorID: 104 -│ User: root +│ ├── • RemoveUserPrivileges +│ │ DescriptorID: 104 +│ │ User: root +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 1 +│ TableID: 108 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 52 elements transitioning toward ABSENT +│ │ ├── • 53 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Namespace:{DescID: 104 (multi_region_test_db-), Name: "multi_region_test_db"} │ │ │ │ ABSENT → PUBLIC @@ -705,7 +794,7 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} │ │ │ │ ABSENT → PUBLIC @@ -714,10 +803,10 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -726,7 +815,7 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -734,8 +823,11 @@ EXPLAIN (ddl, verbose) DROP DATABASE multi_region_test_db CASCADE; │ │ │ ├── • ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ └── • IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ │ ABSENT → PUBLIC diff --git a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion index f7ef82f253d1..525bb75f510f 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion +++ b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion @@ -13,7 +13,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 27 elements transitioning toward ABSENT +│ ├── • 29 elements transitioning toward ABSENT │ │ │ │ │ ├── • Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} │ │ │ │ PUBLIC → ABSENT @@ -80,10 +80,25 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} │ │ │ │ PUBLIC → ABSENT @@ -104,16 +119,37 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnFamilyID: 0 (primary-), ColumnID: 2 (crdb_region-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} │ │ │ │ PUBLIC → ABSENT @@ -137,10 +173,13 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column type dependents removed right before column type" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} │ │ │ │ PUBLIC → ABSENT @@ -152,10 +191,16 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -176,10 +221,16 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -199,11 +250,47 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_row-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row_pkey", IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ ├── • IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} │ │ │ │ PUBLIC → ABSENT @@ -223,7 +310,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 24 Mutation operations +│ └── • 38 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 108 @@ -318,6 +405,10 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ DescriptorID: 108 │ │ User: root │ │ +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ │ ├── • RemoveDroppedColumnType │ │ ColumnID: 2 │ │ TableID: 108 @@ -328,14 +419,69 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ - 106 │ │ - 107 │ │ -│ └── • AssertColumnFamilyIsRemoved +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 2 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ +│ ├── • AssertColumnFamilyIsRemoved +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 2 +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ Ordinal: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 2 │ TableID: 108 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 27 elements transitioning toward ABSENT +│ │ ├── • 29 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Namespace:{DescID: 108 (table_regional_by_row-), Name: "table_regional_by_row", ReferencedDescID: 104 (multi_region_test_db)} │ │ │ │ ABSENT → PUBLIC @@ -365,7 +511,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "k", ColumnID: 1 (k-)} │ │ │ │ ABSENT → PUBLIC @@ -374,10 +520,10 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_region", ColumnID: 2 (crdb_region-)} │ │ │ │ ABSENT → PUBLIC @@ -386,13 +532,13 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 108 (table_regional_by_row-), ReferencedTypeIDs: [106 (#106), 107 (#107)], ColumnID: 2 (crdb_region-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -401,7 +547,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_row-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_row-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -409,8 +555,14 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ ├── • ColumnType:{DescID: 108 (table_regional_by_row-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 2 (crdb_region-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_row-), ColumnID: 1 (k-), IndexID: 1 (table_regional_by_row_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • IndexPartitioning:{DescID: 108 (table_regional_by_row-), IndexID: 1 (table_regional_by_row_pkey-)} │ │ │ │ ABSENT → PUBLIC diff --git a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion_primary_region b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion_primary_region index 23ea3234a106..1520bba682e3 100644 --- a/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion_primary_region +++ b/pkg/ccl/schemachangerccl/testdata/explain_verbose/drop_table_multiregion_primary_region @@ -13,7 +13,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 20 elements transitioning toward ABSENT +│ ├── • 21 elements transitioning toward ABSENT │ │ │ │ │ ├── • Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} │ │ │ │ PUBLIC → ABSENT @@ -71,10 +71,25 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (a-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} │ │ │ │ PUBLIC → ABSENT @@ -95,16 +110,25 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -125,10 +149,16 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -148,11 +178,29 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 108 (table_regional_by_table-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ └── • IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ │ PUBLIC → ABSENT @@ -163,7 +211,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 17 Mutation operations +│ └── • 27 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 108 @@ -236,14 +284,55 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ DescriptorID: 108 │ │ User: root │ │ -│ └── • AssertColumnFamilyIsRemoved +│ ├── • AssertColumnFamilyIsRemoved +│ │ TableID: 108 +│ │ +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 108 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 108 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 108 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 1 │ TableID: 108 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 20 elements transitioning toward ABSENT +│ │ ├── • 21 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Namespace:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table", ReferencedDescID: 104 (multi_region_test_db)} │ │ │ │ ABSENT → PUBLIC @@ -270,7 +359,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "a", ColumnID: 1 (a-)} │ │ │ │ ABSENT → PUBLIC @@ -279,10 +368,10 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -291,7 +380,7 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 108 (table_regional_by_table-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 108 (table_regional_by_table-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -299,8 +388,11 @@ EXPLAIN (ddl, verbose) DROP TABLE multi_region_test_db.public.table_regional_by_ │ │ │ ├── • ColumnType:{DescID: 108 (table_regional_by_table-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 108 (table_regional_by_table-), ColumnID: 1 (a-), IndexID: 1 (table_regional_by_table_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 108 (table_regional_by_table-), IndexID: 1 (table_regional_by_table_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ └── • IndexName:{DescID: 108 (table_regional_by_table-), Name: "table_regional_by_table_pkey", IndexID: 1 (table_regional_by_table_pkey-)} │ │ │ ABSENT → PUBLIC diff --git a/pkg/sql/schemachanger/scplan/internal/opgen/op_gen.go b/pkg/sql/schemachanger/scplan/internal/opgen/op_gen.go index a8f2fa806cc8..34274d6a7267 100644 --- a/pkg/sql/schemachanger/scplan/internal/opgen/op_gen.go +++ b/pkg/sql/schemachanger/scplan/internal/opgen/op_gen.go @@ -44,6 +44,7 @@ type Transition interface { From() scpb.Status To() scpb.Status OpType() scop.Type + Revertible() bool } // HasTransient returns true if the element of this type has diff --git a/pkg/sql/schemachanger/scplan/internal/opgen/target.go b/pkg/sql/schemachanger/scplan/internal/opgen/target.go index 6cb1d58282f0..b075677c7235 100644 --- a/pkg/sql/schemachanger/scplan/internal/opgen/target.go +++ b/pkg/sql/schemachanger/scplan/internal/opgen/target.go @@ -49,6 +49,10 @@ func (t transition) To() scpb.Status { return t.to } +func (t transition) Revertible() bool { + return t.revertible +} + func makeTarget(e scpb.Element, spec targetSpec) (t target, err error) { defer func() { err = errors.Wrapf(err, "target %s", spec.to) diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/BUILD.bazel b/pkg/sql/schemachanger/scplan/internal/rules/current/BUILD.bazel index 06c8ed339b04..29c73ee4bcd0 100644 --- a/pkg/sql/schemachanger/scplan/internal/rules/current/BUILD.bazel +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/BUILD.bazel @@ -17,6 +17,7 @@ go_library( "dep_drop_index_and_column.go", "dep_drop_object.go", "dep_garbage_collection.go", + "dep_statement_phase.go", "dep_swap_index.go", "dep_two_version.go", "helpers.go", diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/dep_statement_phase.go b/pkg/sql/schemachanger/scplan/internal/rules/current/dep_statement_phase.go new file mode 100644 index 000000000000..1e7dae23ebcd --- /dev/null +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/dep_statement_phase.go @@ -0,0 +1,149 @@ +// Copyright 2023 The Cockroach Authors. +// +// Use of this software is governed by the Business Source License +// included in the file licenses/BSL.txt. +// +// As of the Change Date specified in that file, in accordance with +// the Business Source License, use of this software will be governed +// by the Apache License, Version 2.0, included in the file +// licenses/APL.txt. + +package current + +import ( + "fmt" + "reflect" + + "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/rel" + "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scpb" + "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scplan/internal/opgen" + . "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scplan/internal/rules" + "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scplan/internal/scgraph" + "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/screl" +) + +func init() { + + findNoopSourceStatuses := func( + el scpb.Element, targetStatus scpb.TargetStatus, + ) map[scpb.Status][]scpb.Status { + // We want to skip the dependency edges if the status which got us into + // the current status was a no-op. We track the no-op status parent nodes, + // and we'll add a not-join to make sure there does not exist a node + // with such a status when installing the rule. + // + // This is necessary to deal with cases like the transition from + // BACKFILL_ONLY to its equivalent DELETE_ONLY in the rollback of an + // ADD COLUMN. We don't want or need a dependency edge from DELETE_ONLY + // to ABSENT in that case, but if we didn't check whether we got to + // DELETE_ONLY from BACKFILL_ONLY, then we'd have one implicitly. + statusMap := map[scpb.Status][]scpb.Status{} + if err := opgen.IterateTransitions(el, targetStatus, func( + t opgen.Transition, + ) error { + if !t.OpType().IsValid() { + statusMap[t.To()] = append(statusMap[t.To()], t.From()) + } + return nil + }); err != nil { + panic(err) + } + return statusMap + } + // Ensures that a descriptor is at most allowed a single transition, + // if it is in an adding state (and the state is revertible). + clausesForStatementPhaseSingleTransition := func( + from, to NodeVars, + el scpb.Element, + targetStatus scpb.TargetStatus, + t opgen.Transition, + prePrevStatuses []scpb.Status, + isDescriptor bool, + ) rel.Clauses { + var descIDVar rel.Var = "desc-id" + clauses := rel.Clauses{ + from.Type(el), + to.Type(el), + from.El.AttrEqVar(screl.DescID, descIDVar), + from.El.AttrEqVar(rel.Self, to.El), + from.Target.AttrEqVar(rel.Self, to.Target), + from.Target.AttrEq(screl.TargetStatus, targetStatus.Status()), + from.Node.AttrEq(screl.CurrentStatus, t.From()), + to.Node.AttrEq(screl.CurrentStatus, t.To()), + } + if !isDescriptor { + targetDesc := MkNodeVars("target-desc") + clauses = append(clauses, + rel.Clauses{ + targetDesc.TypeFilter(rulesVersionKey, IsDescriptor), + targetDesc.JoinTargetNode(), + targetDesc.DescIDEq(descIDVar), + targetDesc.Target.AttrNeq(screl.CurrentStatus, scpb.Status_DESCRIPTOR_ADDED), + }...) + } else if t.Revertible() { + clauses = append(clauses, + from.Target.AttrNeq(screl.CurrentStatus, scpb.Status_DESCRIPTOR_ADDED)) + } + if len(prePrevStatuses) > 0 { + clauses = append(clauses, + GetNotJoinOnNodeWithStatusIn(prePrevStatuses)(from.Target), + ) + } + return clauses + } + + addRules := func(el scpb.Element, targetStatus scpb.TargetStatus, isDescriptor bool) { + statusMap := findNoopSourceStatuses(el, targetStatus) + fromPublicStatus := scpb.Status_UNKNOWN + fromAbsentStatus := scpb.Status_UNKNOWN + + if err := opgen.IterateTransitions(el, targetStatus, func( + t opgen.Transition, + ) error { + if targetStatus == scpb.ToPublic && t.From() == scpb.Status_ABSENT { + fromPublicStatus = t.To() + return nil + } + if targetStatus == scpb.ToAbsent && t.From() == scpb.Status_PUBLIC { + fromAbsentStatus = t.To() + return nil + } + if ((t.From() != fromPublicStatus) && targetStatus == scpb.ToPublic) || + ((t.From() != fromAbsentStatus) && targetStatus == scpb.ToAbsent) { + return nil + } + // This transition is already covered. + if t.From() == scpb.Status_DROPPED && t.To() == scpb.Status_ABSENT { + return nil + } + elemName := reflect.TypeOf(el).Elem().Name() + ruleName := scgraph.RuleName(fmt.Sprintf( + "%s transitions to %s uphold only single transition in statement phase: %s->%s", + elemName, targetStatus.Status(), t.From(), t.To(), + )) + registerDepRule( + ruleName, + scgraph.StatementPhasePrecedence, + "prev", "next", + func(from, to NodeVars) rel.Clauses { + return clausesForStatementPhaseSingleTransition( + from, to, el, targetStatus, t, statusMap[t.From()], + isDescriptor, + ) + }, + ) + return nil + }); err != nil { + panic(err) + } + } + + _ = scpb.ForEachElementType(func(el scpb.Element) error { + isDescriptor := IsDescriptor(el) + if opgen.HasPublic(el) { + addRules(el, scpb.ToPublic, isDescriptor) + } + addRules(el, scpb.ToAbsent, isDescriptor) // every element has ToAbsent + return nil + }) +} diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules b/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules index 66d3c19efbdb..4b85021f79f4 100644 --- a/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules @@ -1,5 +1,21 @@ deprules ---- +- name: 'AliasType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.AliasType' + - $next[Type] = '*scpb.AliasType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -49,6 +65,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CheckConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CheckConstraint' + - $next[Type] = '*scpb.CheckConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -97,6 +133,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CheckConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CheckConstraint' + - $next[Type] = '*scpb.CheckConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' from: prev-Node kind: PreviousStagePrecedence @@ -145,6 +200,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Column transitions to ABSENT uphold only single transition in statement phase: WRITE_ONLY->DELETE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Column' + - $next[Type] = '*scpb.Column' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = DELETE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: ABSENT->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -193,6 +267,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Column transitions to PUBLIC uphold only single transition in statement phase: DELETE_ONLY->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Column' + - $next[Type] = '*scpb.Column' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DELETE_ONLY + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -242,6 +335,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ColumnNotNull transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ColumnNotNull' + - $next[Type] = '*scpb.ColumnNotNull' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -290,6 +403,41 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ColumnNotNull transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ColumnNotNull' + - $next[Type] = '*scpb.ColumnNotNull' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CompositeType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CompositeType' + - $next[Type] = '*scpb.CompositeType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: Constraint should be hidden before name from: constraint-name-Node kind: Precedence @@ -411,6 +559,37 @@ deprules - $column-Node[CurrentStatus] = WRITE_ONLY - joinTargetNode($expr, $expr-Target, $expr-Node) - joinTargetNode($column, $column-Target, $column-Node) +- name: 'Database transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Database' + - $next[Type] = '*scpb.Database' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'EnumType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.EnumType' + - $next[Type] = '*scpb.EnumType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -460,6 +639,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ForeignKeyConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ForeignKeyConstraint' + - $next[Type] = '*scpb.ForeignKeyConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -508,6 +707,40 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ForeignKeyConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ForeignKeyConstraint' + - $next[Type] = '*scpb.ForeignKeyConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Function' + - $next[Type] = '*scpb.Function' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DESCRIPTOR_ADDED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -767,6 +1000,26 @@ deprules - nodeNotExistsWithStatusIn_VALIDATED_TRANSIENT_WRITE_ONLY_MERGE_ONLY_TRANSIENT_MERGE_ONLY_MERGED_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'PrimaryIndex transitions to ABSENT uphold only single transition in statement phase: VALIDATED->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.PrimaryIndex' + - $next[Type] = '*scpb.PrimaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -895,6 +1148,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'PrimaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.PrimaryIndex' + - $next[Type] = '*scpb.PrimaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = BACKFILL_ONLY + - $next-Node[CurrentStatus] = BACKFILLED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -1153,6 +1425,21 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Schema' + - $next[Type] = '*scpb.Schema' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DESCRIPTOR_ADDED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -1283,6 +1570,25 @@ deprules - nodeNotExistsWithStatusIn_VALIDATED_MERGE_ONLY_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'SecondaryIndex transitions to ABSENT uphold only single transition in statement phase: VALIDATED->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.SecondaryIndex' + - $next[Type] = '*scpb.SecondaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -1411,6 +1717,57 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'SecondaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.SecondaryIndex' + - $next[Type] = '*scpb.SecondaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = BACKFILL_ONLY + - $next-Node[CurrentStatus] = BACKFILLED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Sequence transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Sequence' + - $next[Type] = '*scpb.Sequence' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Table transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Table' + - $next[Type] = '*scpb.Table' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' from: prev-Node kind: PreviousStagePrecedence @@ -1589,6 +1946,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $next[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -1637,6 +2014,41 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $next[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'View transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.View' + - $next[Type] = '*scpb.View' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: back-reference in parent descriptor is removed before parent descriptor is dropped from: back-reference-in-parent-descriptor-Node kind: Precedence @@ -3482,6 +3894,22 @@ deprules deprules ---- +- name: 'AliasType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.AliasType' + - $next[Type] = '*scpb.AliasType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -3531,6 +3959,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CheckConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CheckConstraint' + - $next[Type] = '*scpb.CheckConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -3579,6 +4027,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CheckConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CheckConstraint' + - $next[Type] = '*scpb.CheckConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' from: prev-Node kind: PreviousStagePrecedence @@ -3627,6 +4094,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Column transitions to ABSENT uphold only single transition in statement phase: WRITE_ONLY->DELETE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Column' + - $next[Type] = '*scpb.Column' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = DELETE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: ABSENT->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -3675,6 +4161,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Column transitions to PUBLIC uphold only single transition in statement phase: DELETE_ONLY->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Column' + - $next[Type] = '*scpb.Column' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DELETE_ONLY + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -3724,6 +4229,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ColumnNotNull transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ColumnNotNull' + - $next[Type] = '*scpb.ColumnNotNull' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -3772,6 +4297,41 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ColumnNotNull transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ColumnNotNull' + - $next[Type] = '*scpb.ColumnNotNull' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'CompositeType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.CompositeType' + - $next[Type] = '*scpb.CompositeType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: Constraint should be hidden before name from: constraint-name-Node kind: Precedence @@ -3893,6 +4453,37 @@ deprules - $column-Node[CurrentStatus] = WRITE_ONLY - joinTargetNode($expr, $expr-Target, $expr-Node) - joinTargetNode($column, $column-Target, $column-Node) +- name: 'Database transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Database' + - $next[Type] = '*scpb.Database' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'EnumType transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.EnumType' + - $next[Type] = '*scpb.EnumType' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' from: prev-Node kind: PreviousStagePrecedence @@ -3942,6 +4533,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ForeignKeyConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ForeignKeyConstraint' + - $next[Type] = '*scpb.ForeignKeyConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -3990,6 +4601,40 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'ForeignKeyConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.ForeignKeyConstraint' + - $next[Type] = '*scpb.ForeignKeyConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Function' + - $next[Type] = '*scpb.Function' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DESCRIPTOR_ADDED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -4249,6 +4894,26 @@ deprules - nodeNotExistsWithStatusIn_VALIDATED_TRANSIENT_WRITE_ONLY_MERGE_ONLY_TRANSIENT_MERGE_ONLY_MERGED_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'PrimaryIndex transitions to ABSENT uphold only single transition in statement phase: VALIDATED->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.PrimaryIndex' + - $next[Type] = '*scpb.PrimaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -4377,6 +5042,25 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'PrimaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.PrimaryIndex' + - $next[Type] = '*scpb.PrimaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = BACKFILL_ONLY + - $next-Node[CurrentStatus] = BACKFILLED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -4635,6 +5319,21 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Schema' + - $next[Type] = '*scpb.Schema' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DESCRIPTOR_ADDED + - $next-Node[CurrentStatus] = PUBLIC + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -4765,6 +5464,25 @@ deprules - nodeNotExistsWithStatusIn_VALIDATED_MERGE_ONLY_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'SecondaryIndex transitions to ABSENT uphold only single transition in statement phase: VALIDATED->WRITE_ONLY' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.SecondaryIndex' + - $next[Type] = '*scpb.SecondaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = WRITE_ONLY + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: ABSENT->BACKFILL_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -4893,6 +5611,57 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'SecondaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.SecondaryIndex' + - $next[Type] = '*scpb.SecondaryIndex' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = BACKFILL_ONLY + - $next-Node[CurrentStatus] = BACKFILLED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Sequence transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Sequence' + - $next[Type] = '*scpb.Sequence' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'Table transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.Table' + - $next[Type] = '*scpb.Table' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' from: prev-Node kind: PreviousStagePrecedence @@ -5071,6 +5840,26 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $next[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = ABSENT + - $prev-Node[CurrentStatus] = VALIDATED + - $next-Node[CurrentStatus] = ABSENT + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: ABSENT->WRITE_ONLY' from: prev-Node kind: PreviousStagePrecedence @@ -5119,6 +5908,41 @@ deprules - descriptorIsNotBeingDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) +- name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $next[Type] = '*scpb.UniqueWithoutIndexConstraint' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = WRITE_ONLY + - $next-Node[CurrentStatus] = VALIDATED + - $target-desc[Type] IN ['*scpb.AliasType', '*scpb.CompositeType', '*scpb.Database', '*scpb.EnumType', '*scpb.Function', '*scpb.Schema', '*scpb.Sequence', '*scpb.Table', '*scpb.View'] + - joinTargetNode($target-desc, $target-desc-Target, $target-desc-Node) + - $target-desc[DescID] = $desc-id + - $target-desc-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) +- name: 'View transitions to PUBLIC uphold only single transition in statement phase: DROPPED->PUBLIC' + from: prev-Node + kind: StatementPhasePrecedence + to: next-Node + query: + - $prev[Type] = '*scpb.View' + - $next[Type] = '*scpb.View' + - $prev[DescID] = $desc-id + - $prev[Self] = $next + - $prev-Target[Self] = $next-Target + - $prev-Target[TargetStatus] = PUBLIC + - $prev-Node[CurrentStatus] = DROPPED + - $next-Node[CurrentStatus] = PUBLIC + - $prev-Target[CurrentStatus] != DESCRIPTOR_ADDED + - joinTargetNode($prev, $prev-Target, $prev-Node) + - joinTargetNode($next, $next-Target, $next-Node) - name: back-reference in parent descriptor is removed before parent descriptor is dropped from: back-reference-in-parent-descriptor-Node kind: Precedence diff --git a/pkg/sql/schemachanger/scplan/internal/scgraph/depedgekind_string.go b/pkg/sql/schemachanger/scplan/internal/scgraph/depedgekind_string.go index d71aeb3261d6..145634c6469a 100644 --- a/pkg/sql/schemachanger/scplan/internal/scgraph/depedgekind_string.go +++ b/pkg/sql/schemachanger/scplan/internal/scgraph/depedgekind_string.go @@ -12,6 +12,7 @@ func _() { _ = x[SameStagePrecedence-2] _ = x[PreviousStagePrecedence-3] _ = x[PreviousTransactionPrecedence-4] + _ = x[StatementPhasePrecedence-5] } func (i DepEdgeKind) String() string { @@ -24,6 +25,8 @@ func (i DepEdgeKind) String() string { return "PreviousStagePrecedence" case PreviousTransactionPrecedence: return "PreviousTransactionPrecedence" + case StatementPhasePrecedence: + return "StatementPhasePrecedence" default: return "DepEdgeKind(" + strconv.FormatInt(int64(i), 10) + ")" } diff --git a/pkg/sql/schemachanger/scplan/internal/scgraph/edge.go b/pkg/sql/schemachanger/scplan/internal/scgraph/edge.go index 5afa03994699..76ba4ea5a484 100644 --- a/pkg/sql/schemachanger/scplan/internal/scgraph/edge.go +++ b/pkg/sql/schemachanger/scplan/internal/scgraph/edge.go @@ -105,6 +105,11 @@ const ( // release via the release_22_2 ruleset and should not be used elsewhere. // Deprecated. PreviousTransactionPrecedence + + // StatementPhasePrecedence indicates that the source (from) of the edge must + // be reached before the destination (to), and _must_ do so after the statement + // phase. + StatementPhasePrecedence ) // DepEdge represents a dependency between two nodes. A dependency diff --git a/pkg/sql/schemachanger/scplan/internal/scstage/BUILD.bazel b/pkg/sql/schemachanger/scplan/internal/scstage/BUILD.bazel index eaa8cecec91d..c2c29176ee70 100644 --- a/pkg/sql/schemachanger/scplan/internal/scstage/BUILD.bazel +++ b/pkg/sql/schemachanger/scplan/internal/scstage/BUILD.bazel @@ -10,6 +10,7 @@ go_library( importpath = "github.com/cockroachdb/cockroach/pkg/sql/schemachanger/scplan/internal/scstage", visibility = ["//visibility:public"], deps = [ + "//pkg/clusterversion", "//pkg/jobs/jobspb", "//pkg/sql/catalog", "//pkg/sql/catalog/descpb", diff --git a/pkg/sql/schemachanger/scplan/internal/scstage/build.go b/pkg/sql/schemachanger/scplan/internal/scstage/build.go index 477e9c9b48ac..af16344e493f 100644 --- a/pkg/sql/schemachanger/scplan/internal/scstage/build.go +++ b/pkg/sql/schemachanger/scplan/internal/scstage/build.go @@ -16,6 +16,7 @@ import ( "sort" "strings" + "github.com/cockroachdb/cockroach/pkg/clusterversion" "github.com/cockroachdb/cockroach/pkg/jobs/jobspb" "github.com/cockroachdb/cockroach/pkg/sql/catalog" "github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb" @@ -37,6 +38,7 @@ func BuildStages( phase scop.Phase, g *scgraph.Graph, scJobIDSupplier func() jobspb.JobID, + activeVersion clusterversion.ClusterVersion, withSanityChecks bool, ) []Stage { // Initialize the build context. @@ -58,6 +60,7 @@ func BuildStages( current: init.Current, startingPhase: phase, descIDs: screl.AllTargetDescIDs(init.TargetState), + activeVersion: activeVersion, withSanityChecks: withSanityChecks, } // Build stages for all remaining phases. @@ -101,6 +104,7 @@ type buildContext struct { startingPhase scop.Phase descIDs catalog.DescriptorIDSet withSanityChecks bool + activeVersion clusterversion.ClusterVersion } // buildStages builds all stages according to the starting parameters @@ -430,24 +434,32 @@ func (sb stageBuilder) isOutgoingOpEdgeAllowed(e *scgraph.OpEdge) bool { // phase, whether the edge is revertible, and other information. switch sb.bs.currentPhase { case scop.StatementPhase: - // We ignore revertibility in the statement phase. This ensures that - // the side effects of a schema change become immediately visible - // to the transaction. For example, dropping a table in an explicit - // transaction should make it impossible to query that table later - // in the transaction. - // - // That being said, we can't simply allow any op-edge, or the targets from - // previous statements in the same transaction will make progress, which is - // undesirable: in the statement phase we only allow up to one transition - // per target in the whole transaction. This is somewhat arbitrary but it's - // usually enough to ensure the desired in-transaction side effects. - // - // We enforce this at-most-one-transition constraint by checking whether - // the op-edge's origin node status is a potential target status: iff so - // then that node is the source node of the target transition path. - // Otherwise, it means that at least one transition has already occurred - // therefore no further transitions are allowed. - return scpb.AsTargetStatus(e.From().CurrentStatus) != scpb.InvalidTarget + // Before 23.2 this logic would be used to ensure that a statement phase, + // only had one transition. + if !sb.bc.activeVersion.IsActive(clusterversion.V23_2) { + // We ignore revertibility in the statement phase. This ensures that + // the side effects of a schema change become immediately visible + // to the transaction. For example, dropping a table in an explicit + // transaction should make it impossible to query that table later + // in the transaction. + // + // That being said, we can't simply allow any op-edge, or the targets from + // previous statements in the same transaction will make progress, which is + // undesirable: in the statement phase we only allow up to one transition + // per target in the whole transaction. This is somewhat arbitrary but it's + // usually enough to ensure the desired in-transaction side effects. + // + // We enforce this at-most-one-transition constraint by checking whether + // the op-edge's origin node status is a potential target status: iff so + // then that node is the source node of the target transition path. + // Otherwise, it means that at least one transition has already occurred + // therefore no further transitions are allowed. + return scpb.AsTargetStatus(e.From().CurrentStatus) != scpb.InvalidTarget + } + // In 23.2 we have a new rule under dep rule for the statement phase, which + // ensure only one transition exists. i.e. "uphold only single transition in + // statement phase" + return true case scop.PreCommitPhase, scop.PostCommitPhase: // We allow non-revertible ops to be included in stages in these phases // only if none of the remaining schema change operations can fail. @@ -507,6 +519,13 @@ func (sb stageBuilder) isUnmetInboundDep(de *scgraph.DepEdge) bool { // True iff the source node has not been fulfilled in an earlier stage. return !fromIsFulfilled + case scgraph.StatementPhasePrecedence: + if sb.bs.currentPhase != scop.StatementPhase { + return false + } + // True iff the source node has not been fulfilled in an earlier stage. + return !fromIsFulfilled + case scgraph.Precedence: // True iff the source node has not been fulfilled in an earlier stage // and also iff it's not (yet?) scheduled to be fulfilled in this stage. @@ -617,6 +636,18 @@ func (sb stageBuilder) hasUnmeetableOutboundDeps(n *screl.Node) (ret bool) { } ret = true return iterutil.StopIteration() + case scgraph.StatementPhasePrecedence: + // The transition for this dependency edge can only be scheduled, once + // we have passed the statement phase. + if sb.bs.currentPhase != scop.StatementPhase { + return nil + } + if sb.hasDebugTrace() { + sb.debugTracef(" - %s targeting %s must reach %s in after statement phase", + screl.ElementString(de.From().Element()), de.From().TargetStatus, de.From().CurrentStatus) + } + ret = true + return iterutil.StopIteration() case scgraph.Precedence, scgraph.SameStagePrecedence: // `de.from` might be schedulable and, if indeed is, the dep edge types allow // us to schedule `n` in the same stage as `de.from`. Hope remains! diff --git a/pkg/sql/schemachanger/scplan/plan.go b/pkg/sql/schemachanger/scplan/plan.go index 2b2df443875b..11b026dd7249 100644 --- a/pkg/sql/schemachanger/scplan/plan.go +++ b/pkg/sql/schemachanger/scplan/plan.go @@ -133,6 +133,7 @@ func makePlan(ctx context.Context, p *Plan) (err error) { p.Params.ExecutionPhase, p.Graph, p.Params.SchemaChangerJobIDSupplier, + p.Params.ActiveVersion, !p.Params.SkipPlannerSanityChecks, ) if log.ExpensiveLogEnabled(ctx, 2) { diff --git a/pkg/sql/schemachanger/scplan/testdata/alter_table_drop_column b/pkg/sql/schemachanger/scplan/testdata/alter_table_drop_column index e117781e6989..c314cf107e35 100644 --- a/pkg/sql/schemachanger/scplan/testdata/alter_table_drop_column +++ b/pkg/sql/schemachanger/scplan/testdata/alter_table_drop_column @@ -17,7 +17,7 @@ SET sql_safe_updates = false; ops ALTER TABLE defaultdb.foo DROP COLUMN v1 CASCADE; ---- -StatementPhase stage 1 of 1 with 31 MutationType ops +StatementPhase stage 1 of 1 with 41 MutationType ops transitions: [[Column:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY [[ColumnName:{DescID: 107, Name: v1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT @@ -28,19 +28,19 @@ StatementPhase stage 1 of 1 with 31 MutationType ops [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 108}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: v1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ReferencedTypeIDs: [104 105], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: v2, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[PrimaryIndex:{DescID: 107, IndexID: 3, ConstraintID: 3, TemporaryIndexID: 4, SourceIndexID: 1}, PUBLIC], ABSENT] -> BACKFILL_ONLY @@ -179,6 +179,36 @@ StatementPhase stage 1 of 1 with 31 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 108 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 108 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Column:{DescID: 107, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC @@ -190,19 +220,19 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 108}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: v1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ReferencedTypeIDs: [104 105], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: v2, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[PrimaryIndex:{DescID: 107, IndexID: 3, ConstraintID: 3, TemporaryIndexID: 4, SourceIndexID: 1}, PUBLIC], BACKFILL_ONLY] -> ABSENT @@ -1310,7 +1340,7 @@ ALTER TABLE defaultdb.foo DROP COLUMN v1 CASCADE; ops ALTER TABLE defaultdb.foo DROP COLUMN v2 CASCADE; ---- -StatementPhase stage 1 of 1 with 32 MutationType ops +StatementPhase stage 1 of 1 with 42 MutationType ops transitions: [[Column:{DescID: 107, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY [[ColumnName:{DescID: 107, Name: v2, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT @@ -1322,19 +1352,19 @@ StatementPhase stage 1 of 1 with 32 MutationType ops [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 108}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: v1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ReferencedTypeIDs: [104 105], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: v2, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[PrimaryIndex:{DescID: 107, IndexID: 3, ConstraintID: 3, TemporaryIndexID: 4, SourceIndexID: 1}, PUBLIC], ABSENT] -> BACKFILL_ONLY @@ -1476,6 +1506,36 @@ StatementPhase stage 1 of 1 with 32 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 108 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 108 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Column:{DescID: 107, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC @@ -1488,19 +1548,19 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 108}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: v1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ReferencedTypeIDs: [104 105], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: v2, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[PrimaryIndex:{DescID: 107, IndexID: 3, ConstraintID: 3, TemporaryIndexID: 4, SourceIndexID: 1}, PUBLIC], BACKFILL_ONLY] -> ABSENT diff --git a/pkg/sql/schemachanger/scplan/testdata/create_function b/pkg/sql/schemachanger/scplan/testdata/create_function index 57b3129ee873..f790cd587b82 100644 --- a/pkg/sql/schemachanger/scplan/testdata/create_function +++ b/pkg/sql/schemachanger/scplan/testdata/create_function @@ -291,6 +291,10 @@ CREATE FUNCTION f(a notmyworkday) RETURNS INT VOLATILE LANGUAGE SQL AS $$ SELECT nextval('sq1'); $$; ---- +- from: [Function:{DescID: 110}, DESCRIPTOR_ADDED] + to: [Function:{DescID: 110}, PUBLIC] + kind: StatementPhasePrecedence + rule: Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC - from: [Function:{DescID: 110}, DESCRIPTOR_ADDED] to: [FunctionBody:{DescID: 110}, PUBLIC] kind: Precedence diff --git a/pkg/sql/schemachanger/scplan/testdata/create_schema b/pkg/sql/schemachanger/scplan/testdata/create_schema index 906bf7406dea..383b519416b2 100644 --- a/pkg/sql/schemachanger/scplan/testdata/create_schema +++ b/pkg/sql/schemachanger/scplan/testdata/create_schema @@ -115,6 +115,10 @@ CREATE SCHEMA sc; to: [Owner:{DescID: 105}, PUBLIC] kind: Precedence rule: descriptor existence precedes dependents +- from: [Schema:{DescID: 105}, DESCRIPTOR_ADDED] + to: [Schema:{DescID: 105}, PUBLIC] + kind: StatementPhasePrecedence + rule: Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC - from: [Schema:{DescID: 105}, DESCRIPTOR_ADDED] to: [SchemaName:{DescID: 105}, PUBLIC] kind: Precedence diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_database b/pkg/sql/schemachanger/scplan/testdata/drop_database index dd66bdf4ba62..f6feaa9a651d 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_database +++ b/pkg/sql/schemachanger/scplan/testdata/drop_database @@ -19,7 +19,7 @@ COMMENT ON TABLE db1.sc1.t1 IS 't1 is good'; ops DROP DATABASE db1 CASCADE ---- -StatementPhase stage 1 of 1 with 169 MutationType ops +StatementPhase stage 1 of 1 with 241 MutationType ops transitions: [[Namespace:{DescID: 104, Name: db1, ReferencedDescID: 0}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -56,24 +56,27 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[Table:{DescID: 110}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 110, ReferencedDescID: 105}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 110, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 110, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED - [[Column:{DescID: 110, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[ColumnNotNull:{DescID: 110, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 110, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: val, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 110, ColumnID: 3, ReferencedSequenceIDs: [107]}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 110, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 110, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 110, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 110, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 110, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 110, Name: t1_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 108, Name: sq1, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 108}, ABSENT], PUBLIC] -> ABSENT @@ -89,24 +92,27 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[SchemaChild:{DescID: 109, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT [[TableComment:{DescID: 109, Comment: t1 is good}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: val, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 109, ColumnID: 3, ReferencedSequenceIDs: [108]}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 109, Name: t1_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 111, Name: v1, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 111}, ABSENT], PUBLIC] -> ABSENT @@ -114,13 +120,13 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 111}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 111, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 112, Name: v2, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -129,16 +135,16 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[UserPrivileges:{DescID: 112, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 112}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 112, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 112, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 112, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 112, Name: n1, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 112, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 112, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 112, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 112, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 112, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 112, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 112, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 112, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 112, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 113, Name: v3, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -147,16 +153,16 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 113}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 113, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 114, Name: v4, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -165,16 +171,16 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[UserPrivileges:{DescID: 114, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 114}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 114, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 114, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 114, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 114, Name: n2, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 114, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 114, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 114, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 114, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 114, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 114, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 114, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 114, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 114, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 115, Name: typ, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -198,19 +204,19 @@ StatementPhase stage 1 of 1 with 169 MutationType ops [[UserPrivileges:{DescID: 117, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 117}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 117, ReferencedDescID: 106}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 117, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 117, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 117, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 117, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 117, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 117, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 117, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 117, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 117, Name: n1, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 117, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 117, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 117, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 117, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 117, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 117, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -578,6 +584,21 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 110 User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 110 *scop.NotImplementedForPublicObjects DescID: 108 ElementType: scpb.Owner @@ -596,6 +617,21 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 109 User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 109 *scop.NotImplementedForPublicObjects DescID: 111 ElementType: scpb.Owner @@ -605,6 +641,15 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 111 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 111 *scop.NotImplementedForPublicObjects DescID: 112 ElementType: scpb.Owner @@ -614,6 +659,18 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 112 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 112 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 112 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 112 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 112 *scop.NotImplementedForPublicObjects DescID: 113 ElementType: scpb.Owner @@ -623,6 +680,18 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 113 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 113 *scop.NotImplementedForPublicObjects DescID: 114 ElementType: scpb.Owner @@ -632,6 +701,18 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 114 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 114 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 114 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 114 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 114 *scop.NotImplementedForPublicObjects DescID: 115 ElementType: scpb.Owner @@ -665,6 +746,21 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 117 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 117 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 117 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 117 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 117 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 117 *scop.MarkDescriptorAsDropped DescriptorID: 104 *scop.RemoveDatabaseComment @@ -714,6 +810,18 @@ StatementPhase stage 1 of 1 with 169 MutationType ops SchemaID: 105 *scop.AssertColumnFamilyIsRemoved TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 110 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 110 *scop.DrainDescriptorName Namespace: DatabaseID: 104 @@ -728,30 +836,87 @@ StatementPhase stage 1 of 1 with 169 MutationType ops SchemaID: 106 *scop.AssertColumnFamilyIsRemoved TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 109 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 109 *scop.DrainDescriptorName Namespace: DatabaseID: 104 DescriptorID: 111 Name: v1 SchemaID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 111 *scop.DrainDescriptorName Namespace: DatabaseID: 104 DescriptorID: 112 Name: v2 SchemaID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 112 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 112 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 112 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 112 *scop.DrainDescriptorName Namespace: DatabaseID: 104 DescriptorID: 113 Name: v3 SchemaID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 113 *scop.DrainDescriptorName Namespace: DatabaseID: 104 DescriptorID: 114 Name: v4 SchemaID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 114 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 114 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 114 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 114 *scop.DrainDescriptorName Namespace: DatabaseID: 104 @@ -770,6 +935,21 @@ StatementPhase stage 1 of 1 with 169 MutationType ops DescriptorID: 117 Name: v5 SchemaID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 117 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 117 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 117 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 117 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 117 *scop.DrainDescriptorName Namespace: DescriptorID: 104 @@ -786,6 +966,60 @@ StatementPhase stage 1 of 1 with 169 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 104 User: root + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 110 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 110 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 110 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 110 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 109 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 109 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Namespace:{DescID: 104, Name: db1, ReferencedDescID: 0}, ABSENT], ABSENT] -> PUBLIC @@ -823,24 +1057,27 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[Table:{DescID: 110}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 110, ReferencedDescID: 105}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 110, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 110, ColumnID: 1, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[ColumnNotNull:{DescID: 110, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: val, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 110, ColumnID: 3, ReferencedSequenceIDs: [107]}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 110, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 110, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 110, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 110, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 110, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 110, Name: t1_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 108, Name: sq1, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 108}, ABSENT], ABSENT] -> PUBLIC @@ -856,24 +1093,27 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[SchemaChild:{DescID: 109, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC [[TableComment:{DescID: 109, Comment: t1 is good}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: val, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 109, ColumnID: 3, ReferencedSequenceIDs: [108]}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 109, Name: t1_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 111, Name: v1, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 111}, ABSENT], ABSENT] -> PUBLIC @@ -881,13 +1121,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 111}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 111, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 112, Name: v2, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC @@ -896,16 +1136,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 112, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 112}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 112, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 112, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 112, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 112, Name: n1, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 112, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 112, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 112, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 112, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 112, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 112, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 112, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 112, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 112, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 112, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 113, Name: v3, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC @@ -914,16 +1154,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 113}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 113, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 114, Name: v4, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC @@ -932,16 +1172,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 114, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 114}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 114, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 114, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 114, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 114, Name: n2, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 114, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 114, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 114, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 114, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 114, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 114, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 114, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 114, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 114, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 114, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 115, Name: typ, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC @@ -965,19 +1205,19 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 117, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 117}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 117, ReferencedDescID: 106}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 117, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 117, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 117, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 117, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 117, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 117, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 117, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 117, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 117, Name: n1, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 117, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 117, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 117, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 117, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 117, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 117, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 117, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_index b/pkg/sql/schemachanger/scplan/testdata/drop_index index 08b64a69d208..68d0e1ac35ab 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_index +++ b/pkg/sql/schemachanger/scplan/testdata/drop_index @@ -665,7 +665,7 @@ DROP INDEX idx3 CASCADE ops DROP INDEX idx4 CASCADE ---- -StatementPhase stage 1 of 1 with 14 MutationType ops +StatementPhase stage 1 of 1 with 20 MutationType ops transitions: [[SecondaryIndex:{DescID: 104, IndexID: 8, ConstraintID: 5}, ABSENT], PUBLIC] -> VALIDATED [[Namespace:{DescID: 105, Name: v, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -674,13 +674,13 @@ StatementPhase stage 1 of 1 with 14 MutationType ops [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 105}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: count, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -732,6 +732,24 @@ StatementPhase stage 1 of 1 with 14 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 105 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 105 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[SecondaryIndex:{DescID: 104, IndexID: 8, ConstraintID: 5}, ABSENT], VALIDATED] -> PUBLIC @@ -741,13 +759,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 105}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: count, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: @@ -1140,7 +1158,7 @@ DROP INDEX idx4 CASCADE ops DROP INDEX v2@idx CASCADE; ---- -StatementPhase stage 1 of 1 with 21 MutationType ops +StatementPhase stage 1 of 1 with 34 MutationType ops transitions: [[SecondaryIndex:{DescID: 106, IndexID: 2, ConstraintID: 0}, ABSENT], PUBLIC] -> VALIDATED [[Namespace:{DescID: 107, Name: v3, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -1150,21 +1168,23 @@ StatementPhase stage 1 of 1 with 21 MutationType ops [[View:{DescID: 107}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 107, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 107, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: j, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: rowid, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 107, ColumnID: 2, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED + [[ColumnNotNull:{DescID: 107, ColumnID: 2, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 107, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 107, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 107, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 107, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 107, Name: v3_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT ops: *scop.MarkDescriptorAsDropped @@ -1235,8 +1255,50 @@ StatementPhase stage 1 of 1 with 21 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 107 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 107 + *scop.RemoveColumnNotNull + ColumnID: 2 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 107 *scop.AssertColumnFamilyIsRemoved TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 107 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 107 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + TableID: 107 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + Kind: 2 + TableID: 107 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 107 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[SecondaryIndex:{DescID: 106, IndexID: 2, ConstraintID: 0}, ABSENT], VALIDATED] -> PUBLIC @@ -1247,21 +1309,23 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[View:{DescID: 107}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 107, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 107, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: j, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: rowid, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 107, ColumnID: 2, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC + [[ColumnNotNull:{DescID: 107, ColumnID: 2, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 107, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 107, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 107, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 107, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 107, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 107, Name: v3_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC ops: *scop.UndoAllInTxnImmediateMutationOpSideEffects diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_owned_by b/pkg/sql/schemachanger/scplan/testdata/drop_owned_by index f6502ec8038a..db1d8de6dbdf 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_owned_by +++ b/pkg/sql/schemachanger/scplan/testdata/drop_owned_by @@ -17,7 +17,7 @@ CREATE VIEW s.v2 AS (SELECT 'a'::s.typ::string AS k, name FROM s.v1); ops DROP OWNED BY r ---- -StatementPhase stage 1 of 1 with 108 MutationType ops +StatementPhase stage 1 of 1 with 154 MutationType ops transitions: [[UserPrivileges:{DescID: 100, Name: r}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 105, Name: s, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -40,24 +40,27 @@ StatementPhase stage 1 of 1 with 108 MutationType ops [[Table:{DescID: 109}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 109, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: val, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 109, ColumnID: 3, ReferencedSequenceIDs: [106]}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 109, Name: t_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 107, Name: sq, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 107}, ABSENT], PUBLIC] -> ABSENT @@ -72,24 +75,27 @@ StatementPhase stage 1 of 1 with 108 MutationType ops [[Table:{DescID: 108}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 108, ReferencedDescID: 105}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 108, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 108, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[ColumnNotNull:{DescID: 108, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: val, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 108, ColumnID: 3, ReferencedSequenceIDs: [107]}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 108, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 108, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 108, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 108, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 108, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 108, Name: t_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 110, Name: v1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 110}, ABSENT], PUBLIC] -> ABSENT @@ -97,13 +103,13 @@ StatementPhase stage 1 of 1 with 108 MutationType ops [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 110}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 110, ReferencedDescID: 105}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 111, Name: typ, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -127,16 +133,16 @@ StatementPhase stage 1 of 1 with 108 MutationType ops [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 113}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 113, ReferencedDescID: 105}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -393,6 +399,21 @@ StatementPhase stage 1 of 1 with 108 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 109 User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 109 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -423,6 +444,21 @@ StatementPhase stage 1 of 1 with 108 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 108 User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 108 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -438,6 +474,15 @@ StatementPhase stage 1 of 1 with 108 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 110 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 110 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -489,6 +534,18 @@ StatementPhase stage 1 of 1 with 108 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 113 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 113 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -505,8 +562,107 @@ StatementPhase stage 1 of 1 with 108 MutationType ops User: root *scop.AssertColumnFamilyIsRemoved TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 109 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 109 *scop.AssertColumnFamilyIsRemoved TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 108 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 113 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 109 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 108 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 108 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 108 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 108 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[UserPrivileges:{DescID: 100, Name: r}, ABSENT], ABSENT] -> PUBLIC @@ -530,24 +686,27 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[Table:{DescID: 109}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 109, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: val, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 109, ColumnID: 3, ReferencedSequenceIDs: [106]}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 109, Name: t_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 107, Name: sq, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 107}, ABSENT], ABSENT] -> PUBLIC @@ -562,24 +721,27 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[Table:{DescID: 108}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 108, ReferencedDescID: 105}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 108, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 108, ColumnID: 1, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[ColumnNotNull:{DescID: 108, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: val, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 108, ColumnID: 3, ReferencedSequenceIDs: [107]}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 108, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 108, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 108, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 108, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 108, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 108, Name: t_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 110, Name: v1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 110}, ABSENT], ABSENT] -> PUBLIC @@ -587,13 +749,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 110}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 110, ReferencedDescID: 105}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 111, Name: typ, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -617,16 +779,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 113}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 113, ReferencedDescID: 105}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_schema b/pkg/sql/schemachanger/scplan/testdata/drop_schema index 4ad137b5baa1..017df881301a 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_schema +++ b/pkg/sql/schemachanger/scplan/testdata/drop_schema @@ -1719,7 +1719,7 @@ DROP SCHEMA defaultdb.SC1 CASCADE ops DROP SCHEMA defaultdb.SC1 CASCADE ---- -StatementPhase stage 1 of 1 with 127 MutationType ops +StatementPhase stage 1 of 1 with 183 MutationType ops transitions: [[Namespace:{DescID: 104, Name: sc1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 104}, ABSENT], PUBLIC] -> ABSENT @@ -1742,24 +1742,27 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[SchemaChild:{DescID: 106, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT [[TableComment:{DescID: 106, Comment: t1 is good table}, ABSENT], PUBLIC] -> ABSENT [[ColumnFamily:{DescID: 106, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[ColumnNotNull:{DescID: 106, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> VALIDATED - [[Column:{DescID: 106, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[ColumnNotNull:{DescID: 106, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 106, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: name, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: val, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnDefaultExpression:{DescID: 106, ColumnID: 3, ReferencedSequenceIDs: [105]}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT - [[PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> VALIDATED + [[IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT [[IndexName:{DescID: 106, Name: t1_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 107, Name: v1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 107}, ABSENT], PUBLIC] -> ABSENT @@ -1767,13 +1770,13 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[UserPrivileges:{DescID: 107, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 107}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 107, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 108, Name: v2, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -1782,16 +1785,16 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 108}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 108, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: n1, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 109, Name: v3, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -1800,16 +1803,16 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[UserPrivileges:{DescID: 109, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 109}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 109, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 110, Name: v4, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -1818,16 +1821,16 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 110}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 110, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: n2, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 111, Name: typ, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -1851,19 +1854,19 @@ StatementPhase stage 1 of 1 with 127 MutationType ops [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 113}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 113, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: n1, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -2174,6 +2177,21 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 106 User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 106 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2189,6 +2207,15 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 107 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 107 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2204,6 +2231,18 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 108 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 108 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2219,6 +2258,18 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 109 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 109 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2234,6 +2285,18 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 110 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 110 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 110 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2285,6 +2348,21 @@ StatementPhase stage 1 of 1 with 127 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 113 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 113 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 113 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -2301,6 +2379,105 @@ StatementPhase stage 1 of 1 with 127 MutationType ops User: root *scop.AssertColumnFamilyIsRemoved TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 106 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 110 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 113 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 113 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 106 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 106 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 106 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 106 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Namespace:{DescID: 104, Name: sc1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -2324,24 +2501,27 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[SchemaChild:{DescID: 106, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC [[TableComment:{DescID: 106, Comment: t1 is good table}, ABSENT], ABSENT] -> PUBLIC [[ColumnFamily:{DescID: 106, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[ColumnNotNull:{DescID: 106, ColumnID: 1, IndexID: 0}, ABSENT], VALIDATED] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[ColumnNotNull:{DescID: 106, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: name, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: val, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnDefaultExpression:{DescID: 106, ColumnID: 3, ReferencedSequenceIDs: [105]}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC - [[PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1}, ABSENT], VALIDATED] -> PUBLIC + [[IndexColumn:{DescID: 106, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 106, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 106, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 106, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC [[IndexName:{DescID: 106, Name: t1_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 107, Name: v1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 107}, ABSENT], ABSENT] -> PUBLIC @@ -2349,13 +2529,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 107, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 107}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 107, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 108, Name: v2, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -2364,16 +2544,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 108}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 108, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: n1, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 109, Name: v3, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -2382,16 +2562,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 109, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 109}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 109, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 110, Name: v4, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -2400,16 +2580,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 110}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 110, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: n2, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 110, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 110, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 110, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 111, Name: typ, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -2433,19 +2613,19 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 113, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 113}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 113, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: n1, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 113, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 113, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 113, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_table b/pkg/sql/schemachanger/scplan/testdata/drop_table index 9a72e25fe84e..883c17d26693 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_table +++ b/pkg/sql/schemachanger/scplan/testdata/drop_table @@ -35,32 +35,91 @@ ALTER TABLE shipments ALTER COLUMN udfcol SET DEFAULT f1(); ops DROP TABLE defaultdb.shipments CASCADE; ---- -StatementPhase stage 1 of 1 with 23 MutationType ops +StatementPhase stage 1 of 1 with 117 MutationType ops transitions: + [[Namespace:{DescID: 109, Name: shipments, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT + [[Owner:{DescID: 109}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 109, Name: admin}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 109, Name: root}, ABSENT], PUBLIC] -> ABSENT + [[Table:{DescID: 109}, ABSENT], PUBLIC] -> DROPPED + [[SchemaChild:{DescID: 109, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT + [[TableComment:{DescID: 109, Comment: shipment is important}, ABSENT], PUBLIC] -> ABSENT + [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: tracking_number, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnComment:{DescID: 109, ColumnID: 1, Comment: tracking_number is a must}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: carrier, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[SequenceOwner:{DescID: 109, ColumnID: 2, ReferencedDescID: 110}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: status, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ReferencedTypeIDs: [107 108], ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 4}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: customer_id, ColumnID: 4}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 5}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: randcol, ColumnID: 5}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 5}, ABSENT], PUBLIC] -> ABSENT + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 5, ReferencedSequenceIDs: [106]}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 6}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: udfcol, ColumnID: 6}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 6}, ABSENT], PUBLIC] -> ABSENT + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 6, ReferencedFunctionIDs: [112]}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 4, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 5, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 6, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexName:{DescID: 109, Name: shipments_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexComment:{DescID: 109, IndexID: 1, Comment: pkey is good}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 4, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[SecondaryIndex:{DescID: 109, IndexID: 2, ConstraintID: 0}, ABSENT], PUBLIC] -> ABSENT + [[IndexName:{DescID: 109, Name: partialidx, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[CheckConstraintUnvalidated:{DescID: 109, ConstraintID: 5, ReferencedSequenceIDs: [106]}, ABSENT], PUBLIC] -> ABSENT [[ConstraintWithoutIndexName:{DescID: 109, Name: check, ConstraintID: 5}, ABSENT], PUBLIC] -> ABSENT - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 2, ReferencedDescID: 104}, ABSENT], PUBLIC] -> VALIDATED + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 2, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_customers, ConstraintID: 2}, ABSENT], PUBLIC] -> ABSENT [[ConstraintComment:{DescID: 109, ConstraintID: 2, Comment: customer is not god}, ABSENT], PUBLIC] -> ABSENT - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 3, ReferencedDescID: 105}, ABSENT], PUBLIC] -> VALIDATED + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 3, ReferencedDescID: 105}, ABSENT], PUBLIC] -> ABSENT [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_orders, ConstraintID: 3}, ABSENT], PUBLIC] -> ABSENT - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 4, ReferencedDescID: 104}, ABSENT], PUBLIC] -> VALIDATED + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 4, ReferencedDescID: 104}, ABSENT], PUBLIC] -> ABSENT [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_customers2, ConstraintID: 4}, ABSENT], PUBLIC] -> ABSENT + [[Namespace:{DescID: 110, Name: sq1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT + [[Owner:{DescID: 110}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 110, Name: admin}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], PUBLIC] -> ABSENT + [[Sequence:{DescID: 110}, ABSENT], PUBLIC] -> DROPPED + [[SchemaChild:{DescID: 110, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 111, Name: v1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 111}, ABSENT], PUBLIC] -> ABSENT [[UserPrivileges:{DescID: 111, Name: admin}, ABSENT], PUBLIC] -> ABSENT [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 111}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 111, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: customer_id, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: carrier, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -92,6 +151,11 @@ StatementPhase stage 1 of 1 with 23 MutationType ops ConstraintID: 4 Name: crdb_internal_constraint_4_name_placeholder TableID: 109 + *scop.MarkDescriptorAsDropped + DescriptorID: 110 + *scop.RemoveObjectParent + ObjectID: 110 + ParentSchemaID: 101 *scop.MarkDescriptorAsDropped DescriptorID: 111 *scop.RemoveBackReferencesInRelations @@ -129,6 +193,42 @@ StatementPhase stage 1 of 1 with 23 MutationType ops ColumnID: 4294967294 Name: crdb_internal_column_4294967294_name_placeholder TableID: 111 + *scop.RemoveForeignKeyBackReference + OriginConstraintID: 2 + OriginTableID: 109 + ReferencedTableID: 104 + *scop.RemoveForeignKeyConstraint + ConstraintID: 2 + TableID: 109 + *scop.RemoveForeignKeyBackReference + OriginConstraintID: 3 + OriginTableID: 109 + ReferencedTableID: 105 + *scop.RemoveForeignKeyConstraint + ConstraintID: 3 + TableID: 109 + *scop.RemoveForeignKeyBackReference + OriginConstraintID: 4 + OriginTableID: 109 + ReferencedTableID: 104 + *scop.RemoveForeignKeyConstraint + ConstraintID: 4 + TableID: 109 + *scop.DrainDescriptorName + Namespace: + DatabaseID: 100 + DescriptorID: 110 + Name: sq1 + SchemaID: 101 + *scop.NotImplementedForPublicObjects + DescID: 110 + ElementType: scpb.Owner + *scop.RemoveUserPrivileges + DescriptorID: 110 + User: admin + *scop.RemoveUserPrivileges + DescriptorID: 110 + User: root *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -144,32 +244,377 @@ StatementPhase stage 1 of 1 with 23 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 111 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 111 + *scop.MarkDescriptorAsDropped + DescriptorID: 109 + *scop.RemoveObjectParent + ObjectID: 109 + ParentSchemaID: 101 + *scop.RemoveTableComment + TableID: 109 + *scop.MakePublicColumnWriteOnly + ColumnID: 1 + TableID: 109 + *scop.SetColumnName + ColumnID: 1 + Name: crdb_internal_column_1_name_placeholder + TableID: 109 + *scop.MakePublicColumnNotNullValidated + ColumnID: 1 + TableID: 109 + *scop.RemoveColumnDefaultExpression + ColumnID: 1 + TableID: 109 + *scop.RemoveColumnComment + ColumnID: 1 + PgAttributeNum: 1 + TableID: 109 + *scop.MakePublicColumnWriteOnly + ColumnID: 2 + TableID: 109 + *scop.SetColumnName + ColumnID: 2 + Name: crdb_internal_column_2_name_placeholder + TableID: 109 + *scop.RemoveSequenceOwner + ColumnID: 2 + OwnedSequenceID: 110 + TableID: 109 + *scop.RemoveOwnerBackReferenceInSequence + SequenceID: 110 + *scop.MakePublicColumnWriteOnly + ColumnID: 3 + TableID: 109 + *scop.SetColumnName + ColumnID: 3 + Name: crdb_internal_column_3_name_placeholder + TableID: 109 + *scop.RemoveDroppedColumnType + ColumnID: 3 + TableID: 109 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 109 + TypeIDs: + - 107 + - 108 + *scop.MakePublicColumnWriteOnly + ColumnID: 4 + TableID: 109 + *scop.SetColumnName + ColumnID: 4 + Name: crdb_internal_column_4_name_placeholder + TableID: 109 + *scop.MakePublicColumnWriteOnly + ColumnID: 5 + TableID: 109 + *scop.SetColumnName + ColumnID: 5 + Name: crdb_internal_column_5_name_placeholder + TableID: 109 + *scop.RemoveColumnDefaultExpression + ColumnID: 5 + TableID: 109 + *scop.UpdateTableBackReferencesInSequences + BackReferencedColumnID: 5 + BackReferencedTableID: 109 + SequenceIDs: + - 106 + *scop.MakePublicColumnWriteOnly + ColumnID: 6 + TableID: 109 + *scop.SetColumnName + ColumnID: 6 + Name: crdb_internal_column_6_name_placeholder + TableID: 109 + *scop.RemoveColumnDefaultExpression + ColumnID: 6 + TableID: 109 + *scop.RemoveTableColumnBackReferencesInFunctions + BackReferencedColumnID: 6 + BackReferencedTableID: 109 + FunctionIDs: + - 112 + *scop.MakePublicColumnWriteOnly + ColumnID: 4294967295 + TableID: 109 + *scop.SetColumnName + ColumnID: 4294967295 + Name: crdb_internal_column_4294967295_name_placeholder + TableID: 109 + *scop.MakePublicColumnWriteOnly + ColumnID: 4294967294 + TableID: 109 + *scop.SetColumnName + ColumnID: 4294967294 + Name: crdb_internal_column_4294967294_name_placeholder + TableID: 109 + *scop.MakePublicPrimaryIndexWriteOnly + IndexID: 1 + TableID: 109 + *scop.SetIndexName + IndexID: 1 + Name: crdb_internal_index_1_name_placeholder + TableID: 109 + *scop.RemoveIndexComment + IndexID: 1 + TableID: 109 + *scop.MakePublicSecondaryIndexWriteOnly + IndexID: 2 + TableID: 109 + *scop.RemoveCheckConstraint + ConstraintID: 5 + TableID: 109 + *scop.UpdateTableBackReferencesInSequences + BackReferencedTableID: 109 + SequenceIDs: + - 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 111 + *scop.DrainDescriptorName + Namespace: + DatabaseID: 100 + DescriptorID: 109 + Name: shipments + SchemaID: 101 + *scop.NotImplementedForPublicObjects + DescID: 109 + ElementType: scpb.Owner + *scop.RemoveUserPrivileges + DescriptorID: 109 + User: admin + *scop.RemoveUserPrivileges + DescriptorID: 109 + User: root + *scop.RemoveColumnNotNull + ColumnID: 1 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 5 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 6 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 109 + *scop.AssertColumnFamilyIsRemoved + TableID: 109 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 109 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 109 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 2 + TableID: 109 + *scop.RemoveDroppedIndexPartialPredicate + IndexID: 2 + TableID: 109 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 109 + TypeIDs: + - 107 + - 108 + *scop.SetIndexName + IndexID: 2 + Name: crdb_internal_index_2_name_placeholder + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 4 + IndexID: 1 + Kind: 2 + Ordinal: 2 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 5 + IndexID: 1 + Kind: 2 + Ordinal: 3 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 6 + IndexID: 1 + Kind: 2 + Ordinal: 4 + TableID: 109 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 2 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 4 + IndexID: 2 + Ordinal: 1 + TableID: 109 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 2 + Kind: 1 + TableID: 109 + *scop.MakeIndexAbsent + IndexID: 2 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 5 + TableID: 109 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 6 + TableID: 109 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: + [[Namespace:{DescID: 109, Name: shipments, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC + [[Owner:{DescID: 109}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 109, Name: admin}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 109, Name: root}, ABSENT], ABSENT] -> PUBLIC + [[Table:{DescID: 109}, ABSENT], DROPPED] -> PUBLIC + [[SchemaChild:{DescID: 109, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC + [[TableComment:{DescID: 109, Comment: shipment is important}, ABSENT], ABSENT] -> PUBLIC + [[ColumnFamily:{DescID: 109, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: tracking_number, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnNotNull:{DescID: 109, ColumnID: 1, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnComment:{DescID: 109, ColumnID: 1, Comment: tracking_number is a must}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: carrier, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[SequenceOwner:{DescID: 109, ColumnID: 2, ReferencedDescID: 110}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: status, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ReferencedTypeIDs: [107 108], ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: customer_id, ColumnID: 4}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 5}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: randcol, ColumnID: 5}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 5}, ABSENT], ABSENT] -> PUBLIC + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 5, ReferencedSequenceIDs: [106]}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 6}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: udfcol, ColumnID: 6}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 6}, ABSENT], ABSENT] -> PUBLIC + [[ColumnDefaultExpression:{DescID: 109, ColumnID: 6, ReferencedFunctionIDs: [112]}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 109, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 109, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 109, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 4, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 5, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 6, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 109, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexName:{DescID: 109, Name: shipments_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexComment:{DescID: 109, IndexID: 1, Comment: pkey is good}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 3, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 4, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 109, ColumnID: 1, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[SecondaryIndex:{DescID: 109, IndexID: 2, ConstraintID: 0}, ABSENT], ABSENT] -> PUBLIC + [[IndexName:{DescID: 109, Name: partialidx, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[CheckConstraintUnvalidated:{DescID: 109, ConstraintID: 5, ReferencedSequenceIDs: [106]}, ABSENT], ABSENT] -> PUBLIC [[ConstraintWithoutIndexName:{DescID: 109, Name: check, ConstraintID: 5}, ABSENT], ABSENT] -> PUBLIC - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 2, ReferencedDescID: 104}, ABSENT], VALIDATED] -> PUBLIC + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 2, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_customers, ConstraintID: 2}, ABSENT], ABSENT] -> PUBLIC [[ConstraintComment:{DescID: 109, ConstraintID: 2, Comment: customer is not god}, ABSENT], ABSENT] -> PUBLIC - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 3, ReferencedDescID: 105}, ABSENT], VALIDATED] -> PUBLIC + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 3, ReferencedDescID: 105}, ABSENT], ABSENT] -> PUBLIC [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_orders, ConstraintID: 3}, ABSENT], ABSENT] -> PUBLIC - [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 4, ReferencedDescID: 104}, ABSENT], VALIDATED] -> PUBLIC + [[ForeignKeyConstraint:{DescID: 109, IndexID: 0, ConstraintID: 4, ReferencedDescID: 104}, ABSENT], ABSENT] -> PUBLIC [[ConstraintWithoutIndexName:{DescID: 109, Name: fk_customers2, ConstraintID: 4}, ABSENT], ABSENT] -> PUBLIC + [[Namespace:{DescID: 110, Name: sq1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC + [[Owner:{DescID: 110}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 110, Name: admin}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 110, Name: root}, ABSENT], ABSENT] -> PUBLIC + [[Sequence:{DescID: 110}, ABSENT], DROPPED] -> PUBLIC + [[SchemaChild:{DescID: 110, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 111, Name: v1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC [[Owner:{DescID: 111}, ABSENT], ABSENT] -> PUBLIC [[UserPrivileges:{DescID: 111, Name: admin}, ABSENT], ABSENT] -> PUBLIC [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 111}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 111, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: customer_id, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: carrier, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: @@ -2741,9 +3186,44 @@ CREATE TABLE defaultdb.greeter ( ops DROP TABLE defaultdb.greeter ---- -StatementPhase stage 1 of 1 with 2 MutationType ops +StatementPhase stage 1 of 1 with 55 MutationType ops transitions: - [[CheckConstraint:{DescID: 115, ReferencedTypeIDs: [113 114], IndexID: 0, ConstraintID: 2}, ABSENT], PUBLIC] -> VALIDATED + [[Namespace:{DescID: 115, Name: greeter, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT + [[Owner:{DescID: 115}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 115, Name: admin}, ABSENT], PUBLIC] -> ABSENT + [[UserPrivileges:{DescID: 115, Name: root}, ABSENT], PUBLIC] -> ABSENT + [[Table:{DescID: 115}, ABSENT], PUBLIC] -> DROPPED + [[SchemaChild:{DescID: 115, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT + [[ColumnFamily:{DescID: 115, Name: primary, ColumnFamilyID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 115, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 115, Name: x, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[ColumnDefaultExpression:{DescID: 115, ReferencedTypeIDs: [113 114], ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 115, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 115, Name: y, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 115, ReferencedTypeIDs: [113 114], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT + [[ColumnNotNull:{DescID: 115, ColumnID: 2, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 115, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 115, Name: rowid, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[ColumnNotNull:{DescID: 115, ColumnID: 3, IndexID: 0}, ABSENT], PUBLIC] -> ABSENT + [[ColumnDefaultExpression:{DescID: 115, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 115, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 115, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT + [[Column:{DescID: 115, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[ColumnName:{DescID: 115, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 115, ColumnID: 3, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 115, ColumnID: 1, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 115, ColumnID: 2, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[PrimaryIndex:{DescID: 115, IndexID: 1, ConstraintID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexName:{DescID: 115, Name: greeter_pkey, IndexID: 1}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 115, ColumnID: 2, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[IndexColumn:{DescID: 115, ColumnID: 3, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[SecondaryIndex:{DescID: 115, IndexID: 2, ConstraintID: 0}, ABSENT], PUBLIC] -> ABSENT + [[IndexName:{DescID: 115, Name: i, IndexID: 2}, ABSENT], PUBLIC] -> ABSENT + [[CheckConstraint:{DescID: 115, ReferencedTypeIDs: [113 114], IndexID: 0, ConstraintID: 2}, ABSENT], PUBLIC] -> ABSENT [[ConstraintWithoutIndexName:{DescID: 115, Name: check, ConstraintID: 2}, ABSENT], PUBLIC] -> ABSENT ops: *scop.MakePublicCheckConstraintValidated @@ -2753,9 +3233,228 @@ StatementPhase stage 1 of 1 with 2 MutationType ops ConstraintID: 2 Name: crdb_internal_constraint_2_name_placeholder TableID: 115 + *scop.RemoveCheckConstraint + ConstraintID: 2 + TableID: 115 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 115 + TypeIDs: + - 113 + - 114 + *scop.MarkDescriptorAsDropped + DescriptorID: 115 + *scop.RemoveObjectParent + ObjectID: 115 + ParentSchemaID: 101 + *scop.MakePublicColumnWriteOnly + ColumnID: 1 + TableID: 115 + *scop.SetColumnName + ColumnID: 1 + Name: crdb_internal_column_1_name_placeholder + TableID: 115 + *scop.RemoveColumnDefaultExpression + ColumnID: 1 + TableID: 115 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 115 + TypeIDs: + - 113 + - 114 + *scop.MakePublicColumnWriteOnly + ColumnID: 2 + TableID: 115 + *scop.SetColumnName + ColumnID: 2 + Name: crdb_internal_column_2_name_placeholder + TableID: 115 + *scop.RemoveDroppedColumnType + ColumnID: 2 + TableID: 115 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 115 + TypeIDs: + - 113 + - 114 + *scop.MakePublicColumnNotNullValidated + ColumnID: 2 + TableID: 115 + *scop.MakePublicColumnWriteOnly + ColumnID: 3 + TableID: 115 + *scop.SetColumnName + ColumnID: 3 + Name: crdb_internal_column_3_name_placeholder + TableID: 115 + *scop.MakePublicColumnNotNullValidated + ColumnID: 3 + TableID: 115 + *scop.RemoveColumnDefaultExpression + ColumnID: 3 + TableID: 115 + *scop.MakePublicColumnWriteOnly + ColumnID: 4294967295 + TableID: 115 + *scop.SetColumnName + ColumnID: 4294967295 + Name: crdb_internal_column_4294967295_name_placeholder + TableID: 115 + *scop.MakePublicColumnWriteOnly + ColumnID: 4294967294 + TableID: 115 + *scop.SetColumnName + ColumnID: 4294967294 + Name: crdb_internal_column_4294967294_name_placeholder + TableID: 115 + *scop.MakePublicPrimaryIndexWriteOnly + IndexID: 1 + TableID: 115 + *scop.SetIndexName + IndexID: 1 + Name: crdb_internal_index_1_name_placeholder + TableID: 115 + *scop.MakePublicSecondaryIndexWriteOnly + IndexID: 2 + TableID: 115 + *scop.DrainDescriptorName + Namespace: + DatabaseID: 100 + DescriptorID: 115 + Name: greeter + SchemaID: 101 + *scop.NotImplementedForPublicObjects + DescID: 115 + ElementType: scpb.Owner + *scop.RemoveUserPrivileges + DescriptorID: 115 + User: admin + *scop.RemoveUserPrivileges + DescriptorID: 115 + User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 115 + *scop.RemoveColumnNotNull + ColumnID: 2 + TableID: 115 + *scop.RemoveColumnNotNull + ColumnID: 3 + TableID: 115 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 115 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 115 + *scop.AssertColumnFamilyIsRemoved + TableID: 115 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 115 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 115 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 115 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 115 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 1 + TableID: 115 + *scop.MakeWriteOnlyIndexDeleteOnly + IndexID: 2 + TableID: 115 + *scop.RemoveDroppedIndexPartialPredicate + IndexID: 2 + TableID: 115 + *scop.UpdateTableBackReferencesInTypes + BackReferencedTableID: 115 + TypeIDs: + - 113 + - 114 + *scop.SetIndexName + IndexID: 2 + Name: crdb_internal_index_2_name_placeholder + TableID: 115 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 1 + TableID: 115 + *scop.RemoveColumnFromIndex + ColumnID: 1 + IndexID: 1 + Kind: 2 + TableID: 115 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 1 + Kind: 2 + Ordinal: 1 + TableID: 115 + *scop.MakeIndexAbsent + IndexID: 1 + TableID: 115 + *scop.RemoveColumnFromIndex + ColumnID: 2 + IndexID: 2 + TableID: 115 + *scop.RemoveColumnFromIndex + ColumnID: 3 + IndexID: 2 + Kind: 1 + TableID: 115 + *scop.MakeIndexAbsent + IndexID: 2 + TableID: 115 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 115 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 115 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 115 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: - [[CheckConstraint:{DescID: 115, ReferencedTypeIDs: [113 114], IndexID: 0, ConstraintID: 2}, ABSENT], VALIDATED] -> PUBLIC + [[Namespace:{DescID: 115, Name: greeter, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC + [[Owner:{DescID: 115}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 115, Name: admin}, ABSENT], ABSENT] -> PUBLIC + [[UserPrivileges:{DescID: 115, Name: root}, ABSENT], ABSENT] -> PUBLIC + [[Table:{DescID: 115}, ABSENT], DROPPED] -> PUBLIC + [[SchemaChild:{DescID: 115, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC + [[ColumnFamily:{DescID: 115, Name: primary, ColumnFamilyID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 115, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 115, Name: x, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[ColumnDefaultExpression:{DescID: 115, ReferencedTypeIDs: [113 114], ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 115, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 115, Name: y, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 115, ReferencedTypeIDs: [113 114], ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC + [[ColumnNotNull:{DescID: 115, ColumnID: 2, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 115, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 115, Name: rowid, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[ColumnNotNull:{DescID: 115, ColumnID: 3, IndexID: 0}, ABSENT], ABSENT] -> PUBLIC + [[ColumnDefaultExpression:{DescID: 115, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 115, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 115, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC + [[Column:{DescID: 115, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[ColumnName:{DescID: 115, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[ColumnType:{DescID: 115, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 115, ColumnID: 3, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 115, ColumnID: 1, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 115, ColumnID: 2, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[PrimaryIndex:{DescID: 115, IndexID: 1, ConstraintID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexName:{DescID: 115, Name: greeter_pkey, IndexID: 1}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 115, ColumnID: 2, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[IndexColumn:{DescID: 115, ColumnID: 3, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[SecondaryIndex:{DescID: 115, IndexID: 2, ConstraintID: 0}, ABSENT], ABSENT] -> PUBLIC + [[IndexName:{DescID: 115, Name: i, IndexID: 2}, ABSENT], ABSENT] -> PUBLIC + [[CheckConstraint:{DescID: 115, ReferencedTypeIDs: [113 114], IndexID: 0, ConstraintID: 2}, ABSENT], ABSENT] -> PUBLIC [[ConstraintWithoutIndexName:{DescID: 115, Name: check, ConstraintID: 2}, ABSENT], ABSENT] -> PUBLIC ops: *scop.UndoAllInTxnImmediateMutationOpSideEffects diff --git a/pkg/sql/schemachanger/scplan/testdata/drop_view b/pkg/sql/schemachanger/scplan/testdata/drop_view index 6f1dcf5414e6..1511ddc313d5 100644 --- a/pkg/sql/schemachanger/scplan/testdata/drop_view +++ b/pkg/sql/schemachanger/scplan/testdata/drop_view @@ -6,7 +6,7 @@ CREATE VIEW defaultdb.v1 AS (SELECT name FROM defaultdb.t1); ops DROP VIEW defaultdb.v1 ---- -StatementPhase stage 1 of 1 with 13 MutationType ops +StatementPhase stage 1 of 1 with 19 MutationType ops transitions: [[Namespace:{DescID: 105, Name: v1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 105}, ABSENT], PUBLIC] -> ABSENT @@ -14,13 +14,13 @@ StatementPhase stage 1 of 1 with 13 MutationType ops [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 105}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -69,6 +69,24 @@ StatementPhase stage 1 of 1 with 13 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 105 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 105 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Namespace:{DescID: 105, Name: v1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -77,13 +95,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 105}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: @@ -388,7 +406,7 @@ CREATE VIEW v5 AS (SELECT 'a'::defaultdb.typ::string AS k, n2, n1 from defaultdb ops DROP VIEW defaultdb.v1 CASCADE ---- -StatementPhase stage 1 of 1 with 76 MutationType ops +StatementPhase stage 1 of 1 with 116 MutationType ops transitions: [[Namespace:{DescID: 105, Name: v1, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT [[Owner:{DescID: 105}, ABSENT], PUBLIC] -> ABSENT @@ -396,13 +414,13 @@ StatementPhase stage 1 of 1 with 76 MutationType ops [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 105}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 106, Name: v2, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -411,16 +429,16 @@ StatementPhase stage 1 of 1 with 76 MutationType ops [[UserPrivileges:{DescID: 106, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 106}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 106, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: n1, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 106, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 107, Name: v3, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -429,16 +447,16 @@ StatementPhase stage 1 of 1 with 76 MutationType ops [[UserPrivileges:{DescID: 107, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 107}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 107, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: name, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 108, Name: v4, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -447,16 +465,16 @@ StatementPhase stage 1 of 1 with 76 MutationType ops [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 108}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: n2, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: n1, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[Namespace:{DescID: 111, Name: v5, ReferencedDescID: 100}, ABSENT], PUBLIC] -> ABSENT @@ -465,19 +483,19 @@ StatementPhase stage 1 of 1 with 76 MutationType ops [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], PUBLIC] -> ABSENT [[View:{DescID: 111}, ABSENT], PUBLIC] -> DROPPED [[SchemaChild:{DescID: 111, ReferencedDescID: 101}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: k, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 2}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: n2, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 3}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: n1, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], PUBLIC] -> ABSENT - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> WRITE_ONLY + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], PUBLIC] -> ABSENT ops: @@ -687,6 +705,15 @@ StatementPhase stage 1 of 1 with 76 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 105 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 105 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 105 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -702,6 +729,18 @@ StatementPhase stage 1 of 1 with 76 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 106 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 106 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 106 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -717,6 +756,18 @@ StatementPhase stage 1 of 1 with 76 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 107 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 107 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 107 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -732,6 +783,18 @@ StatementPhase stage 1 of 1 with 76 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 108 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 108 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 108 *scop.DrainDescriptorName Namespace: DatabaseID: 100 @@ -747,6 +810,81 @@ StatementPhase stage 1 of 1 with 76 MutationType ops *scop.RemoveUserPrivileges DescriptorID: 111 User: root + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 1 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 2 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 3 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967295 + TableID: 111 + *scop.MakeWriteOnlyColumnDeleteOnly + ColumnID: 4294967294 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 105 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 106 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 107 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 108 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 1 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 2 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 3 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967295 + TableID: 111 + *scop.MakeDeleteOnlyColumnAbsent + ColumnID: 4294967294 + TableID: 111 PreCommitPhase stage 1 of 2 with 1 MutationType op transitions: [[Namespace:{DescID: 105, Name: v1, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -755,13 +893,13 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 105, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 105}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 105, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 105, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 105, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 105, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 106, Name: v2, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -770,16 +908,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 106, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 106}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 106, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: n1, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 106, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 106, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 106, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 107, Name: v3, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -788,16 +926,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 107, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 107}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 107, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: name, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 107, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 107, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 107, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 108, Name: v4, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -806,16 +944,16 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 108, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 108}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 108, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: n2, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: n1, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 108, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 108, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 108, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[Namespace:{DescID: 111, Name: v5, ReferencedDescID: 100}, ABSENT], ABSENT] -> PUBLIC @@ -824,19 +962,19 @@ PreCommitPhase stage 1 of 2 with 1 MutationType op [[UserPrivileges:{DescID: 111, Name: root}, ABSENT], ABSENT] -> PUBLIC [[View:{DescID: 111}, ABSENT], DROPPED] -> PUBLIC [[SchemaChild:{DescID: 111, ReferencedDescID: 101}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 1}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: k, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 1}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 2}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: n2, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 2}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 3}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: n1, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 3}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: crdb_internal_mvcc_timestamp, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967295}, ABSENT], ABSENT] -> PUBLIC - [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], WRITE_ONLY] -> PUBLIC + [[Column:{DescID: 111, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnName:{DescID: 111, Name: tableoid, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC [[ColumnType:{DescID: 111, ColumnFamilyID: 0, ColumnID: 4294967294}, ABSENT], ABSENT] -> PUBLIC ops: diff --git a/pkg/sql/schemachanger/testdata/end_to_end/create_function_in_txn b/pkg/sql/schemachanger/testdata/end_to_end/create_function_in_txn index b649f9c8c91e..a5a7f6679cb1 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/create_function_in_txn +++ b/pkg/sql/schemachanger/testdata/end_to_end/create_function_in_txn @@ -78,7 +78,7 @@ write *eventpb.CreateIndex to event log: tag: CREATE INDEX user: root tableName: defaultdb.public.t -## StatementPhase stage 1 of 1 with 7 MutationType ops +## StatementPhase stage 1 of 1 with 8 MutationType ops upsert descriptor #104 ... id: 104 @@ -148,6 +148,13 @@ upsert descriptor #104 unexposedParentSchemaId: 101 - version: "1" + version: "2" +upsert descriptor #105 + ... + oid: 20 + width: 64 + - state: ADD + version: "1" + volatility: VOLATILE # end StatementPhase # begin PreCommitPhase ## PreCommitPhase stage 1 of 2 with 1 MutationType op diff --git a/pkg/sql/schemachanger/testdata/end_to_end/drop_column_create_index_separate_statements b/pkg/sql/schemachanger/testdata/end_to_end/drop_column_create_index_separate_statements index 3a646d0d4171..0fa4acc7ab25 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/drop_column_create_index_separate_statements +++ b/pkg/sql/schemachanger/testdata/end_to_end/drop_column_create_index_separate_statements @@ -241,7 +241,47 @@ write *eventpb.CreateIndex to event log: tag: CREATE INDEX user: root tableName: defaultdb.public.t -## StatementPhase stage 1 of 1 with no ops +## StatementPhase stage 1 of 1 with 8 MutationType ops +upsert descriptor #104 + ... + direction: DROP + mutationId: 1 + - state: WRITE_ONLY + + state: DELETE_ONLY + - direction: DROP + index: + ... + keySuffixColumnIds: + - 1 + - name: t_expr_k_idx + + name: crdb_internal_index_2_name_placeholder + partitioning: {} + sharded: {} + version: 3 + mutationId: 1 + - state: WRITE_ONLY + + state: DELETE_ONLY + - direction: ADD + index: + ... + version: 4 + mutationId: 1 + - state: DELETE_ONLY + + state: WRITE_ONLY + - column: + computeExpr: crdb_internal_column_2_name_placeholder + 1:::INT8 + ... + direction: DROP + mutationId: 1 + - state: WRITE_ONLY + + state: DELETE_ONLY + name: t + nextColumnId: 5 + ... + time: {} + unexposedParentSchemaId: 101 + - version: "1" + + version: "2" # end StatementPhase # begin PreCommitPhase ## PreCommitPhase stage 1 of 2 with 1 MutationType op diff --git a/pkg/sql/schemachanger/testdata/end_to_end/drop_index_with_materialized_view_dep b/pkg/sql/schemachanger/testdata/end_to_end/drop_index_with_materialized_view_dep index 18bcf6f9797c..1244e8722c05 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/drop_index_with_materialized_view_dep +++ b/pkg/sql/schemachanger/testdata/end_to_end/drop_index_with_materialized_view_dep @@ -45,7 +45,7 @@ write *eventpb.DropIndex to event log: tag: DROP INDEX user: root tableName: defaultdb.public.v2 -## StatementPhase stage 1 of 1 with 21 MutationType ops +## StatementPhase stage 1 of 1 with 34 MutationType ops delete object namespace entry {100 101 v3} -> 106 upsert descriptor #105 ... diff --git a/pkg/sql/schemachanger/testdata/end_to_end/drop_multiple_columns_separate_statements b/pkg/sql/schemachanger/testdata/end_to_end/drop_multiple_columns_separate_statements index 5c898991d25b..a89aad4b0f14 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/drop_multiple_columns_separate_statements +++ b/pkg/sql/schemachanger/testdata/end_to_end/drop_multiple_columns_separate_statements @@ -261,7 +261,7 @@ write *eventpb.AlterTable to event log: tag: ALTER TABLE user: root tableName: defaultdb.public.t -## StatementPhase stage 1 of 1 with 2 MutationType ops +## StatementPhase stage 1 of 1 with 10 MutationType ops upsert descriptor #104 ... oid: 20 @@ -284,6 +284,13 @@ upsert descriptor #104 + - crdb_internal_column_3_name_placeholder name: primary formatVersion: 3 + ... + direction: DROP + mutationId: 1 + - state: WRITE_ONLY + + state: DELETE_ONLY + - direction: DROP + index: ... keyColumnNames: - crdb_internal_column_4_name_placeholder @@ -291,6 +298,16 @@ upsert descriptor #104 + - crdb_internal_column_3_name_placeholder keySuffixColumnIds: - 1 + - name: t_expr_k_idx + + name: crdb_internal_index_2_name_placeholder + partitioning: {} + sharded: {} + version: 3 + mutationId: 1 + - state: WRITE_ONLY + + state: DELETE_ONLY + - direction: ADD + index: ... - 3 storeColumnNames: @@ -305,9 +322,16 @@ upsert descriptor #104 + - crdb_internal_column_3_name_placeholder unique: true useDeletePreservingEncoding: true + version: 4 + mutationId: 1 + - state: DELETE_ONLY + + state: WRITE_ONLY + - column: + computeExpr: crdb_internal_column_2_name_placeholder + 1:::INT8 ... + direction: DROP mutationId: 1 - state: WRITE_ONLY + + state: DELETE_ONLY + - column: + defaultExpr: 32:::INT8 + id: 3 @@ -320,9 +344,8 @@ upsert descriptor #104 + width: 64 + direction: DROP + mutationId: 1 - + state: WRITE_ONLY + state: WRITE_ONLY name: t - nextColumnId: 5 ... storeColumnNames: - crdb_internal_column_2_name_placeholder diff --git a/pkg/sql/schemachanger/testdata/end_to_end/drop_table b/pkg/sql/schemachanger/testdata/end_to_end/drop_table index eb6e375634e0..feaf227983b1 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/drop_table +++ b/pkg/sql/schemachanger/testdata/end_to_end/drop_table @@ -27,7 +27,7 @@ write *eventpb.DropTable to event log: tag: DROP TABLE user: root tableName: db.sc.t -## StatementPhase stage 1 of 1 with 22 MutationType ops +## StatementPhase stage 1 of 1 with 38 MutationType ops delete object namespace entry {104 106 t} -> 107 upsert descriptor #107 ... diff --git a/pkg/sql/schemachanger/testdata/end_to_end/drop_table_udf_default b/pkg/sql/schemachanger/testdata/end_to_end/drop_table_udf_default index 2329f6b38239..d7d5d4799dee 100644 --- a/pkg/sql/schemachanger/testdata/end_to_end/drop_table_udf_default +++ b/pkg/sql/schemachanger/testdata/end_to_end/drop_table_udf_default @@ -19,7 +19,7 @@ write *eventpb.DropTable to event log: tag: DROP TABLE user: root tableName: defaultdb.public.t -## StatementPhase stage 1 of 1 with 20 MutationType ops +## StatementPhase stage 1 of 1 with 33 MutationType ops delete object namespace entry {100 101 t} -> 105 upsert descriptor #104 function: diff --git a/pkg/sql/schemachanger/testdata/explain/create_function_in_txn.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain/create_function_in_txn.statement_2_of_2 index 8b5bfb230a5d..f33e4ad5f4a8 100644 --- a/pkg/sql/schemachanger/testdata/explain/create_function_in_txn.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/create_function_in_txn.statement_2_of_2 @@ -11,17 +11,19 @@ Schema change plan for CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.‹publi AS $$SELECT ‹1›;$$; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 5 elements transitioning toward PUBLIC - │ │ ├── ABSENT → BACKFILL_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (idx+), ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1 (t_pkey)} - │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 2 (idx+)} - │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 2 (idx+)} - │ │ ├── ABSENT → PUBLIC IndexData:{DescID: 104 (t), IndexID: 2 (idx+)} - │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104 (t), Name: "idx", IndexID: 2 (idx+)} + │ ├── 6 elements transitioning toward PUBLIC + │ │ ├── DESCRIPTOR_ADDED → PUBLIC Function:{DescID: 105 (t+)} + │ │ ├── ABSENT → BACKFILL_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (idx+), ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1 (t_pkey)} + │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 2 (idx+)} + │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 2 (idx+)} + │ │ ├── ABSENT → PUBLIC IndexData:{DescID: 104 (t), IndexID: 2 (idx+)} + │ │ └── ABSENT → PUBLIC IndexName:{DescID: 104 (t), Name: "idx", IndexID: 2 (idx+)} │ ├── 3 elements transitioning toward TRANSIENT_ABSENT - │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 3, ConstraintID: 3, SourceIndexID: 1 (t_pkey)} - │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 3} - │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 3} - │ └── 7 Mutation operations + │ │ ├── ABSENT → DELETE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 3, ConstraintID: 3, SourceIndexID: 1 (t_pkey)} + │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 3} + │ │ └── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 3} + │ └── 8 Mutation operations + │ ├── MarkDescriptorAsPublic {"DescriptorID":105} │ ├── MakeAbsentIndexBackfilling {"IsSecondaryIndex":true} │ ├── AddColumnToIndex {"ColumnID":2,"IndexID":2,"TableID":104} │ ├── AddColumnToIndex {"ColumnID":1,"IndexID":2,"Kind":1,"TableID":104} @@ -32,22 +34,22 @@ Schema change plan for CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.‹publi ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase │ │ ├── 12 elements transitioning toward PUBLIC - │ │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (t+)} - │ │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t+), Name: "admin"} - │ │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t+), Name: "root"} - │ │ │ ├── DESCRIPTOR_ADDED → ABSENT Function:{DescID: 105 (t+)} - │ │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} - │ │ │ ├── PUBLIC → ABSENT FunctionName:{DescID: 105 (t+)} - │ │ │ ├── PUBLIC → ABSENT FunctionBody:{DescID: 105 (t+)} - │ │ │ ├── BACKFILL_ONLY → ABSENT SecondaryIndex:{DescID: 104 (t), IndexID: 2 (idx+), ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1 (t_pkey)} - │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 2 (idx+)} - │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 2 (idx+)} - │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 2 (idx+)} - │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104 (t), Name: "idx", IndexID: 2 (idx+)} + │ │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (t+)} + │ │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t+), Name: "admin"} + │ │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t+), Name: "root"} + │ │ │ ├── PUBLIC → ABSENT Function:{DescID: 105 (t+)} + │ │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} + │ │ │ ├── PUBLIC → ABSENT FunctionName:{DescID: 105 (t+)} + │ │ │ ├── PUBLIC → ABSENT FunctionBody:{DescID: 105 (t+)} + │ │ │ ├── BACKFILL_ONLY → ABSENT SecondaryIndex:{DescID: 104 (t), IndexID: 2 (idx+), ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1 (t_pkey)} + │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 2 (idx+)} + │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 2 (idx+)} + │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 2 (idx+)} + │ │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104 (t), Name: "idx", IndexID: 2 (idx+)} │ │ ├── 3 elements transitioning toward TRANSIENT_ABSENT - │ │ │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 3, ConstraintID: 3, SourceIndexID: 1 (t_pkey)} - │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 3} - │ │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 3} + │ │ │ ├── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 3, ConstraintID: 3, SourceIndexID: 1 (t_pkey)} + │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 2 (b), IndexID: 3} + │ │ │ └── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (a), IndexID: 3} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 index afba6815c05b..84e4c6ac2b3e 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_column_create_index_separate_statements.statement_2_of_2 @@ -8,6 +8,26 @@ EXPLAIN (ddl) CREATE UNIQUE INDEX idx ON t(k); Schema change plan for CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.‹public›.‹t› (‹k›); following ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── ABSENT → PUBLIC IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} + │ │ └── DELETE_ONLY → WRITE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} + │ ├── 7 elements transitioning toward ABSENT + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104 (t), ColumnID: 2 (j-)} + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} + │ └── 8 Mutation operations + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":104} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4,"TableID":104} + │ ├── MakeDeleteOnlyIndexWriteOnly {"IndexID":4,"TableID":104} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":2,"TableID":104} + │ ├── SetIndexName {"IndexID":2,"Name":"crdb_internal_in...","TableID":104} + │ ├── RemoveColumnFromIndex {"ColumnID":4,"IndexID":2,"TableID":104} + │ ├── RemoveColumnFromIndex {"ColumnID":3,"IndexID":2,"Ordinal":1,"TableID":104} + │ └── RemoveColumnFromIndex {"ColumnID":1,"IndexID":2,"Kind":1,"TableID":104} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase │ │ ├── 4 elements transitioning toward PUBLIC @@ -15,14 +35,19 @@ Schema change plan for CREATE UNIQUE INDEX ‹idx› ON ‹defaultdb›.‹publi │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 3 (t_pkey+)} │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 3 (t_pkey+)} │ │ │ └── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104 (t), IndexID: 3 (t_pkey+), ConstraintID: 2, TemporaryIndexID: 4 (crdb_internal_index_4_name_placeholder), SourceIndexID: 1 (t_pkey-)} - │ │ ├── 3 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 4 (crdb_internal_index_4_name_placeholder)} - │ │ │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} - │ │ ├── 5 elements transitioning toward ABSENT - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 2 (j-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} - │ │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} + │ │ │ └── WRITE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} + │ │ ├── 9 elements transitioning toward ABSENT + │ │ │ ├── DELETE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 2 (j-)} + │ │ │ ├── DELETE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── DELETE_ONLY → PUBLIC SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104 (t), Name: "j", ColumnID: 2 (j-)} │ │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104 (t), Name: "crdb_internal_idx_expr", ColumnID: 4 (crdb_internal_idx_expr-)} │ │ └── 1 Mutation operation diff --git a/pkg/sql/schemachanger/testdata/explain/drop_index_with_materialized_view_dep b/pkg/sql/schemachanger/testdata/explain/drop_index_with_materialized_view_dep index 539249d87136..ba3c6aff0aad 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_index_with_materialized_view_dep +++ b/pkg/sql/schemachanger/testdata/explain/drop_index_with_materialized_view_dep @@ -10,32 +10,34 @@ EXPLAIN (ddl) DROP INDEX idx CASCADE; Schema change plan for DROP INDEX ‹defaultdb›.‹public›.‹v2›@‹idx› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 24 elements transitioning toward ABSENT - │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 106 (v3-), Name: "v3", ReferencedDescID: 100 (defaultdb)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 106 (v3-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (v3-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (v3-), Name: "root"} - │ │ ├── PUBLIC → DROPPED View:{DescID: 106 (v3-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 106 (v3-), ReferencedDescID: 101 (public)} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 106 (v3-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (j-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (rowid-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} - │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} - │ └── 21 Mutation operations + │ ├── 26 elements transitioning toward ABSENT + │ │ ├── PUBLIC → VALIDATED SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 106 (v3-), Name: "v3", ReferencedDescID: 100 (defaultdb)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 106 (v3-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (v3-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 106 (v3-), Name: "root"} + │ │ ├── PUBLIC → DROPPED View:{DescID: 106 (v3-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 106 (v3-), ReferencedDescID: 101 (public)} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 106 (v3-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (j-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} + │ └── 34 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":106} │ ├── RemoveBackReferencesInRelations {"BackReferencedID":106} │ ├── RemoveObjectParent {"ObjectID":106,"ParentSchemaID":101} @@ -56,34 +58,49 @@ Schema change plan for DROP INDEX ‹defaultdb›.‹public›.‹v2›@‹idx │ ├── NotImplementedForPublicObjects {"DescID":106,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":106,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":106,"User":"root"} - │ └── AssertColumnFamilyIsRemoved {"TableID":106} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":106} + │ ├── RemoveColumnNotNull {"ColumnID":2,"TableID":106} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":106} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":106} + │ ├── AssertColumnFamilyIsRemoved {"TableID":106} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":106} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":106} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":106} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":106} + │ ├── RemoveColumnFromIndex {"ColumnID":2,"IndexID":1,"TableID":106} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"Kind":2,"TableID":106} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":106} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":106} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":2,"TableID":106} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 24 elements transitioning toward ABSENT - │ │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 106 (v3-), Name: "v3", ReferencedDescID: 100 (defaultdb)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 106 (v3-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (v3-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (v3-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC View:{DescID: 106 (v3-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 106 (v3-), ReferencedDescID: 101 (public)} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 106 (v3-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (j-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (rowid-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} - │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} + │ │ ├── 26 elements transitioning toward ABSENT + │ │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 106 (v3-), Name: "v3", ReferencedDescID: 100 (defaultdb)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 106 (v3-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (v3-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 106 (v3-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC View:{DescID: 106 (v3-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 106 (v3-), ReferencedDescID: 101 (public)} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 106 (v3-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (j-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 index 87806efcc3ed..d306d56a5c6b 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain/drop_multiple_columns_separate_statements.statement_2_of_2 @@ -8,27 +8,50 @@ EXPLAIN (ddl) ALTER TABLE t DROP COLUMN k CASCADE; Schema change plan for ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹k› CASCADE; following ALTER TABLE ‹defaultdb›.‹public›.‹t› DROP COLUMN ‹j› CASCADE; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 2 elements transitioning toward ABSENT - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 3 (k-)} - │ │ └── PUBLIC → ABSENT ColumnName:{DescID: 104 (t), Name: "k", ColumnID: 3 (k-)} - │ └── 2 Mutation operations + │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── ABSENT → PUBLIC IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} + │ │ └── DELETE_ONLY → WRITE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} + │ ├── 9 elements transitioning toward ABSENT + │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 3 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 104 (t), Name: "k", ColumnID: 3 (k-)} + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104 (t), ColumnID: 2 (j-)} + │ │ ├── WRITE_ONLY → DELETE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 3 (k-), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} + │ │ ├── VALIDATED → DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} + │ └── 10 Mutation operations │ ├── MakePublicColumnWriteOnly {"ColumnID":3,"TableID":104} - │ └── SetColumnName {"ColumnID":3,"Name":"crdb_internal_co...","TableID":104} + │ ├── SetColumnName {"ColumnID":3,"Name":"crdb_internal_co...","TableID":104} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":104} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4,"TableID":104} + │ ├── MakeDeleteOnlyIndexWriteOnly {"IndexID":4,"TableID":104} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":2,"TableID":104} + │ ├── SetIndexName {"IndexID":2,"Name":"crdb_internal_in...","TableID":104} + │ ├── RemoveColumnFromIndex {"ColumnID":4,"IndexID":2,"TableID":104} + │ ├── RemoveColumnFromIndex {"ColumnID":3,"IndexID":2,"Ordinal":1,"TableID":104} + │ └── RemoveColumnFromIndex {"ColumnID":1,"IndexID":2,"Kind":1,"TableID":104} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase │ │ ├── 3 elements transitioning toward PUBLIC │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 3 (t_pkey+)} │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 3 (t_pkey+)} │ │ │ └── BACKFILL_ONLY → ABSENT PrimaryIndex:{DescID: 104 (t), IndexID: 3 (t_pkey+), ConstraintID: 2, TemporaryIndexID: 4 (crdb_internal_index_4_name_placeholder), SourceIndexID: 1 (t_pkey-)} - │ │ ├── 2 elements transitioning toward TRANSIENT_ABSENT + │ │ ├── 3 elements transitioning toward TRANSIENT_ABSENT │ │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} - │ │ │ └── DELETE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} - │ │ ├── 7 elements transitioning toward ABSENT + │ │ │ ├── PUBLIC → ABSENT IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} + │ │ │ └── WRITE_ONLY → ABSENT TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} + │ │ ├── 11 elements transitioning toward ABSENT │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 3 (k-)} │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104 (t), Name: "k", ColumnID: 3 (k-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 2 (j-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} - │ │ │ ├── VALIDATED → PUBLIC SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── DELETE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 2 (j-)} + │ │ │ ├── DELETE_ONLY → PUBLIC Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 3 (k-), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── DELETE_ONLY → PUBLIC SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} + │ │ │ ├── ABSENT → PUBLIC IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 104 (t), Name: "j", ColumnID: 2 (j-)} │ │ │ └── ABSENT → PUBLIC ColumnName:{DescID: 104 (t), Name: "crdb_internal_idx_expr", ColumnID: 4 (crdb_internal_idx_expr-)} │ │ └── 1 Mutation operation diff --git a/pkg/sql/schemachanger/testdata/explain/drop_table b/pkg/sql/schemachanger/testdata/explain/drop_table index b487865e0bea..b707c7a3e88d 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_table +++ b/pkg/sql/schemachanger/testdata/explain/drop_table @@ -11,35 +11,38 @@ EXPLAIN (ddl) DROP TABLE db.sc.t; Schema change plan for DROP TABLE ‹db›.‹sc›.‹t›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 27 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 107 (t-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (t-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (t-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Table:{DescID: 107 (t-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 107 (t-), ReferencedDescID: 106 (sc)} - │ │ ├── PUBLIC → ABSENT TableComment:{DescID: 107 (t-), Comment: "t has a comment"} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 107 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 1 (k-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 2 (v-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (v-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 3 (rowid-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} - │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} - │ └── 22 Mutation operations + │ ├── 30 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 107 (t-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (t-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 107 (t-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Table:{DescID: 107 (t-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 107 (t-), ReferencedDescID: 106 (sc)} + │ │ ├── PUBLIC → ABSENT TableComment:{DescID: 107 (t-), Comment: "t has a comment"} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 107 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 107 (t-), ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 107 (t-), ColumnID: 2 (v-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (v-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 3 (rowid-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} + │ └── 38 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":107} │ ├── RemoveObjectParent {"ObjectID":107,"ParentSchemaID":106} │ ├── RemoveTableComment {"TableID":107} @@ -61,37 +64,56 @@ Schema change plan for DROP TABLE ‹db›.‹sc›.‹t›; │ ├── NotImplementedForPublicObjects {"DescID":107,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":107,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":107,"User":"root"} - │ └── AssertColumnFamilyIsRemoved {"TableID":107} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":107} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":107} + │ ├── RemoveColumnNotNull {"ColumnID":3,"TableID":107} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":107} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":107} + │ ├── AssertColumnFamilyIsRemoved {"TableID":107} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":3,"TableID":107} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":107} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":107} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":107} + │ ├── RemoveColumnFromIndex {"ColumnID":3,"IndexID":1,"TableID":107} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"Kind":2,"TableID":107} + │ ├── RemoveColumnFromIndex {"ColumnID":2,"IndexID":1,"Kind":2,"Ordinal":1,"TableID":107} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":107} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":107} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":2,"TableID":107} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":3,"TableID":107} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 27 elements transitioning toward ABSENT - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 107 (t-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (t-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (t-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 107 (t-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 107 (t-), ReferencedDescID: 106 (sc)} - │ │ │ ├── ABSENT → PUBLIC TableComment:{DescID: 107 (t-), Comment: "t has a comment"} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 107 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 107 (t-), ColumnID: 1 (k-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 107 (t-), ColumnID: 2 (v-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (v-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 3 (rowid-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} - │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} + │ │ ├── 30 elements transitioning toward ABSENT + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 107 (t-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (t-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 107 (t-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 107 (t-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 107 (t-), ReferencedDescID: 106 (sc)} + │ │ │ ├── ABSENT → PUBLIC TableComment:{DescID: 107 (t-), Comment: "t has a comment"} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 107 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 107 (t-), ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 107 (t-), ColumnID: 2 (v-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (v-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 3 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/sql/schemachanger/testdata/explain/drop_table_udf_default b/pkg/sql/schemachanger/testdata/explain/drop_table_udf_default index fa492365d230..e1586e877d77 100644 --- a/pkg/sql/schemachanger/testdata/explain/drop_table_udf_default +++ b/pkg/sql/schemachanger/testdata/explain/drop_table_udf_default @@ -8,31 +8,33 @@ EXPLAIN (ddl) DROP TABLE t; Schema change plan for DROP TABLE ‹defaultdb›.‹public›.‹t›; ├── StatementPhase │ └── Stage 1 of 1 in StatementPhase - │ ├── 23 elements transitioning toward ABSENT - │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} - │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (t-)} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t-), Name: "admin"} - │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t-), Name: "root"} - │ │ ├── PUBLIC → DROPPED Table:{DescID: 105 (t-)} - │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 105 (t-), ReferencedDescID: 101 (public)} - │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 105 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 1 (i-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (i-)} - │ │ ├── PUBLIC → VALIDATED ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 2 (b-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (b-)} - │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 105 (t-), ColumnID: 2 (b-), ReferencedFunctionIDs: [104 (#104)]} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ ├── PUBLIC → WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ ├── PUBLIC → VALIDATED PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} - │ │ └── PUBLIC → ABSENT IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} - │ └── 20 Mutation operations + │ ├── 25 elements transitioning toward ABSENT + │ │ ├── PUBLIC → ABSENT Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} + │ │ ├── PUBLIC → ABSENT Owner:{DescID: 105 (t-)} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t-), Name: "admin"} + │ │ ├── PUBLIC → ABSENT UserPrivileges:{DescID: 105 (t-), Name: "root"} + │ │ ├── PUBLIC → DROPPED Table:{DescID: 105 (t-)} + │ │ ├── PUBLIC → ABSENT SchemaChild:{DescID: 105 (t-), ReferencedDescID: 101 (public)} + │ │ ├── PUBLIC → ABSENT ColumnFamily:{DescID: 105 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 105 (t-), ColumnID: 1 (i-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (i-)} + │ │ ├── PUBLIC → ABSENT ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 105 (t-), ColumnID: 2 (b-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (b-)} + │ │ ├── PUBLIC → ABSENT ColumnDefaultExpression:{DescID: 105 (t-), ColumnID: 2 (b-), ReferencedFunctionIDs: [104 (#104)]} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ ├── PUBLIC → ABSENT Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} + │ │ ├── PUBLIC → ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} + │ │ ├── PUBLIC → ABSENT PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} + │ │ └── PUBLIC → ABSENT IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} + │ └── 33 Mutation operations │ ├── MarkDescriptorAsDropped {"DescriptorID":105} │ ├── RemoveObjectParent {"ObjectID":105,"ParentSchemaID":101} │ ├── MakePublicColumnWriteOnly {"ColumnID":1,"TableID":105} @@ -52,33 +54,48 @@ Schema change plan for DROP TABLE ‹defaultdb›.‹public›.‹t›; │ ├── NotImplementedForPublicObjects {"DescID":105,"ElementType":"scpb.Owner"} │ ├── RemoveUserPrivileges {"DescriptorID":105,"User":"admin"} │ ├── RemoveUserPrivileges {"DescriptorID":105,"User":"root"} - │ └── AssertColumnFamilyIsRemoved {"TableID":105} + │ ├── RemoveColumnNotNull {"ColumnID":1,"TableID":105} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":2,"TableID":105} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967295,"TableID":105} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":4294967294,"TableID":105} + │ ├── AssertColumnFamilyIsRemoved {"TableID":105} + │ ├── MakeWriteOnlyColumnDeleteOnly {"ColumnID":1,"TableID":105} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967295,"TableID":105} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":4294967294,"TableID":105} + │ ├── MakeWriteOnlyIndexDeleteOnly {"IndexID":1,"TableID":105} + │ ├── RemoveColumnFromIndex {"ColumnID":1,"IndexID":1,"TableID":105} + │ ├── RemoveColumnFromIndex {"ColumnID":2,"IndexID":1,"Kind":2,"TableID":105} + │ ├── MakeIndexAbsent {"IndexID":1,"TableID":105} + │ ├── MakeDeleteOnlyColumnAbsent {"ColumnID":1,"TableID":105} + │ └── MakeDeleteOnlyColumnAbsent {"ColumnID":2,"TableID":105} ├── PreCommitPhase │ ├── Stage 1 of 2 in PreCommitPhase - │ │ ├── 23 elements transitioning toward ABSENT - │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} - │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 105 (t-)} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (t-), Name: "admin"} - │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (t-), Name: "root"} - │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 105 (t-)} - │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 105 (t-), ReferencedDescID: 101 (public)} - │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 105 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 105 (t-), ColumnID: 1 (i-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (i-)} - │ │ │ ├── VALIDATED → PUBLIC ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 105 (t-), ColumnID: 2 (b-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (b-)} - │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 105 (t-), ColumnID: 2 (b-), ReferencedFunctionIDs: [104 (#104)]} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} - │ │ │ ├── WRITE_ONLY → PUBLIC Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} - │ │ │ ├── VALIDATED → PUBLIC PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} - │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} + │ │ ├── 25 elements transitioning toward ABSENT + │ │ │ ├── ABSENT → PUBLIC Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} + │ │ │ ├── ABSENT → PUBLIC Owner:{DescID: 105 (t-)} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (t-), Name: "admin"} + │ │ │ ├── ABSENT → PUBLIC UserPrivileges:{DescID: 105 (t-), Name: "root"} + │ │ │ ├── DROPPED → PUBLIC Table:{DescID: 105 (t-)} + │ │ │ ├── ABSENT → PUBLIC SchemaChild:{DescID: 105 (t-), ReferencedDescID: 101 (public)} + │ │ │ ├── ABSENT → PUBLIC ColumnFamily:{DescID: 105 (t-), Name: "primary", ColumnFamilyID: 0 (primary-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 105 (t-), ColumnID: 1 (i-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (i-)} + │ │ │ ├── ABSENT → PUBLIC ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 105 (t-), ColumnID: 2 (b-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (b-)} + │ │ │ ├── ABSENT → PUBLIC ColumnDefaultExpression:{DescID: 105 (t-), ColumnID: 2 (b-), ReferencedFunctionIDs: [104 (#104)]} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} + │ │ │ ├── ABSENT → PUBLIC Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} + │ │ │ ├── ABSENT → PUBLIC IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} + │ │ │ ├── ABSENT → PUBLIC PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} + │ │ │ └── ABSENT → PUBLIC IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ └── 1 Mutation operation │ │ └── UndoAllInTxnImmediateMutationOpSideEffects │ └── Stage 2 of 2 in PreCommitPhase diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/create_function b/pkg/sql/schemachanger/testdata/explain_verbose/create_function index 9d784f8e6d0d..5580684c047c 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/create_function +++ b/pkg/sql/schemachanger/testdata/explain_verbose/create_function @@ -246,6 +246,9 @@ $$; │ ├── • Function:{DescID: 110 (f+)} │ │ │ ABSENT → PUBLIC │ │ │ + │ │ ├── • StatementPhasePrecedence dependency from DESCRIPTOR_ADDED Function:{DescID: 110 (f+)} + │ │ │ rule: "Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC" + │ │ │ │ │ ├── • Precedence dependency from PUBLIC SchemaChild:{DescID: 110 (f+), ReferencedDescID: 101 (public)} │ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_1_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_1_of_2 index 9ba2965cd4fb..7741f57eb444 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_1_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_1_of_2 @@ -149,6 +149,9 @@ EXPLAIN (ddl, verbose) CREATE FUNCTION t() RETURNS INT LANGUAGE SQL AS $$ SELECT │ ├── • Function:{DescID: 105 (t+)} │ │ │ ABSENT → PUBLIC │ │ │ + │ │ ├── • StatementPhasePrecedence dependency from DESCRIPTOR_ADDED Function:{DescID: 105 (t+)} + │ │ │ rule: "Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC" + │ │ │ │ │ ├── • Precedence dependency from PUBLIC SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} │ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_2_of_2 index 6dc8a50f491e..745017171a18 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/create_function_in_txn.statement_2_of_2 @@ -14,7 +14,31 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(b); │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 5 elements transitioning toward PUBLIC +│ ├── • 6 elements transitioning toward PUBLIC +│ │ │ +│ │ ├── • Function:{DescID: 105 (t+)} +│ │ │ │ DESCRIPTOR_ADDED → PUBLIC +│ │ │ │ +│ │ │ ├── • Precedence dependency from PUBLIC Owner:{DescID: 105 (t+)} +│ │ │ │ rule: "dependents exist before descriptor becomes public" +│ │ │ │ +│ │ │ ├── • Precedence dependency from PUBLIC UserPrivileges:{DescID: 105 (t+), Name: "admin"} +│ │ │ │ rule: "dependents exist before descriptor becomes public" +│ │ │ │ +│ │ │ ├── • Precedence dependency from PUBLIC UserPrivileges:{DescID: 105 (t+), Name: "root"} +│ │ │ │ rule: "dependents exist before descriptor becomes public" +│ │ │ │ +│ │ │ ├── • StatementPhasePrecedence dependency from DESCRIPTOR_ADDED Function:{DescID: 105 (t+)} +│ │ │ │ rule: "Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC" +│ │ │ │ +│ │ │ ├── • Precedence dependency from PUBLIC SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} +│ │ │ │ rule: "dependents exist before descriptor becomes public" +│ │ │ │ +│ │ │ ├── • Precedence dependency from PUBLIC FunctionName:{DescID: 105 (t+)} +│ │ │ │ rule: "dependents exist before descriptor becomes public" +│ │ │ │ +│ │ │ └── • Precedence dependency from PUBLIC FunctionBody:{DescID: 105 (t+)} +│ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ │ │ ├── • SecondaryIndex:{DescID: 104 (t), IndexID: 2 (idx+), ConstraintID: 2, TemporaryIndexID: 3, SourceIndexID: 1 (t_pkey)} │ │ │ │ ABSENT → BACKFILL_ONLY @@ -66,7 +90,10 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(b); │ │ └── • Precedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 3, ConstraintID: 3, SourceIndexID: 1 (t_pkey)} │ │ rule: "temp index existence precedes index dependents" │ │ -│ └── • 7 Mutation operations +│ └── • 8 Mutation operations +│ │ +│ ├── • MarkDescriptorAsPublic +│ │ DescriptorID: 105 │ │ │ ├── • MakeAbsentIndexBackfilling │ │ Index: @@ -130,7 +157,7 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(b); │ │ │ │ PUBLIC → ABSENT │ │ │ │ │ │ │ ├── • Function:{DescID: 105 (t+)} -│ │ │ │ DESCRIPTOR_ADDED → ABSENT +│ │ │ │ PUBLIC → ABSENT │ │ │ │ │ │ │ ├── • SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} │ │ │ │ PUBLIC → ABSENT @@ -599,6 +626,9 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(b); │ │ │ ├── • Precedence dependency from PUBLIC UserPrivileges:{DescID: 105 (t+), Name: "root"} │ │ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ │ + │ │ │ ├── • StatementPhasePrecedence dependency from DESCRIPTOR_ADDED Function:{DescID: 105 (t+)} + │ │ │ │ rule: "Function transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC" + │ │ │ │ │ │ │ ├── • Precedence dependency from PUBLIC SchemaChild:{DescID: 105 (t+), ReferencedDescID: 101 (public)} │ │ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ │ diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/create_schema b/pkg/sql/schemachanger/testdata/explain_verbose/create_schema index d046ca8547e5..ada8bd588c15 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/create_schema +++ b/pkg/sql/schemachanger/testdata/explain_verbose/create_schema @@ -128,6 +128,9 @@ EXPLAIN (ddl, verbose) CREATE SCHEMA sc; │ ├── • Schema:{DescID: 104 (sc+)} │ │ │ ABSENT → PUBLIC │ │ │ + │ │ ├── • StatementPhasePrecedence dependency from DESCRIPTOR_ADDED Schema:{DescID: 104 (sc+)} + │ │ │ rule: "Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC" + │ │ │ │ │ ├── • Precedence dependency from PUBLIC SchemaName:{DescID: 104 (sc+)} │ │ │ rule: "dependents exist before descriptor becomes public" │ │ │ diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 index f72cab2e272b..4c5c4153d9dd 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_column_create_index_separate_statements.statement_2_of_2 @@ -10,6 +10,116 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); ├── • StatementPhase │ │ │ └── • Stage 1 of 1 in StatementPhase +│ │ +│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT +│ │ │ +│ │ ├── • IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ └── • SameStagePrecedence dependency from WRITE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ │ rule: "temp index data exists as soon as temp index accepts writes" +│ │ │ +│ │ └── • TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ │ DELETE_ONLY → WRITE_ONLY +│ │ │ +│ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ rule: "index-column added to index before temp index receives writes" +│ │ │ +│ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ rule: "index-column added to index before temp index receives writes" +│ │ │ +│ │ └── • PreviousStagePrecedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ rule: "TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY" +│ │ +│ ├── • 7 elements transitioning toward ABSENT +│ │ │ +│ │ ├── • Column:{DescID: 104 (t), ColumnID: 2 (j-)} +│ │ │ │ WRITE_ONLY → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 2 (j-)} +│ │ │ rule: "Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY" +│ │ │ +│ │ ├── • Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ │ WRITE_ONLY → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ rule: "Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ VALIDATED → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from VALIDATED SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "SecondaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY" +│ │ │ +│ │ └── • IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} +│ │ │ PUBLIC → ABSENT +│ │ │ +│ │ ├── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index no longer public before index name" +│ │ │ +│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ rule: "index no longer public before dependents, excluding columns" +│ │ +│ └── • 8 Mutation operations +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 104 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4 +│ │ TableID: 104 +│ │ +│ ├── • MakeDeleteOnlyIndexWriteOnly +│ │ IndexID: 4 +│ │ TableID: 104 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 2 +│ │ TableID: 104 +│ │ +│ ├── • SetIndexName +│ │ IndexID: 2 +│ │ Name: crdb_internal_index_2_name_placeholder +│ │ TableID: 104 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 4 +│ │ IndexID: 2 +│ │ TableID: 104 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 3 +│ │ IndexID: 2 +│ │ Ordinal: 1 +│ │ TableID: 104 +│ │ +│ └── • RemoveColumnFromIndex +│ ColumnID: 1 +│ IndexID: 2 +│ Kind: 1 +│ TableID: 104 │ ├── • PreCommitPhase │ │ @@ -29,7 +139,7 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ │ │ └── • PrimaryIndex:{DescID: 104 (t), IndexID: 3 (t_pkey+), ConstraintID: 2, TemporaryIndexID: 4 (crdb_internal_index_4_name_placeholder), SourceIndexID: 1 (t_pkey-)} │ │ │ BACKFILL_ONLY → ABSENT │ │ │ -│ │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT +│ │ ├── • 4 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} │ │ │ │ PUBLIC → ABSENT @@ -37,19 +147,34 @@ EXPLAIN (ddl, verbose) CREATE UNIQUE INDEX idx ON t(k); │ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 4 (crdb_internal_index_4_name_placeholder)} │ │ │ │ PUBLIC → ABSENT │ │ │ │ +│ │ │ ├── • IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ │ │ │ └── • TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} -│ │ │ DELETE_ONLY → ABSENT +│ │ │ WRITE_ONLY → ABSENT │ │ │ -│ │ ├── • 5 elements transitioning toward ABSENT +│ │ ├── • 9 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 2 (j-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 3 (k), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 104 (t), Name: "j", ColumnID: 2 (j-)} │ │ │ │ ABSENT → PUBLIC diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_index_with_materialized_view_dep b/pkg/sql/schemachanger/testdata/explain_verbose/drop_index_with_materialized_view_dep index 048a43f01b0a..f6c294960797 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_index_with_materialized_view_dep +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_index_with_materialized_view_dep @@ -13,7 +13,7 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 24 elements transitioning toward ABSENT +│ ├── • 26 elements transitioning toward ABSENT │ │ │ │ │ ├── • SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} │ │ │ │ PUBLIC → VALIDATED @@ -77,10 +77,19 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (j-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} │ │ │ │ PUBLIC → ABSENT @@ -101,10 +110,28 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} │ │ │ │ PUBLIC → ABSENT @@ -128,7 +155,10 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ rule: "column type dependents removed right before column type" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} -│ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} │ │ │ │ PUBLIC → ABSENT @@ -140,10 +170,16 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -164,10 +200,16 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -187,11 +229,44 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED View:{DescID: 106 (v3-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ └── • IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} │ │ │ PUBLIC → ABSENT @@ -202,7 +277,7 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 21 Mutation operations +│ └── • 34 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 106 @@ -292,14 +367,69 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ DescriptorID: 106 │ │ User: root │ │ -│ └── • AssertColumnFamilyIsRemoved +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 106 +│ │ +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 2 +│ │ TableID: 106 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 106 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 106 +│ │ +│ ├── • AssertColumnFamilyIsRemoved +│ │ TableID: 106 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 106 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 106 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 106 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 106 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 2 +│ │ IndexID: 1 +│ │ TableID: 106 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ Kind: 2 +│ │ TableID: 106 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 106 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 1 +│ │ TableID: 106 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 2 │ TableID: 106 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 24 elements transitioning toward ABSENT +│ │ ├── • 26 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • SecondaryIndex:{DescID: 105 (v2), IndexID: 2 (idx-)} │ │ │ │ VALIDATED → PUBLIC @@ -326,7 +456,7 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 1 (j-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "j", ColumnID: 1 (j-)} │ │ │ │ ABSENT → PUBLIC @@ -335,7 +465,7 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "rowid", ColumnID: 2 (rowid-)} │ │ │ │ ABSENT → PUBLIC @@ -344,13 +474,13 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 106 (v3-), ColumnID: 2 (rowid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -359,7 +489,7 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 106 (v3-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 106 (v3-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -367,8 +497,14 @@ EXPLAIN (ddl, verbose) DROP INDEX idx CASCADE; │ │ │ ├── • ColumnType:{DescID: 106 (v3-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 106 (v3-), ColumnID: 2 (rowid-), IndexID: 1 (v3_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 106 (v3-), ColumnID: 1 (j-), IndexID: 1 (v3_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 106 (v3-), IndexID: 1 (v3_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ └── • IndexName:{DescID: 106 (v3-), Name: "v3_pkey", IndexID: 1 (v3_pkey-)} │ │ │ ABSENT → PUBLIC diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 index f96a3385d22e..c878b450beb6 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_multiple_columns_separate_statements.statement_2_of_2 @@ -11,7 +11,24 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 2 elements transitioning toward ABSENT +│ ├── • 2 elements transitioning toward TRANSIENT_ABSENT +│ │ │ +│ │ ├── • IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ └── • SameStagePrecedence dependency from WRITE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ │ rule: "temp index data exists as soon as temp index accepts writes" +│ │ │ +│ │ └── • TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ │ DELETE_ONLY → WRITE_ONLY +│ │ │ +│ │ ├── • Precedence dependency from PUBLIC IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ rule: "index-column added to index before temp index receives writes" +│ │ │ +│ │ └── • PreviousStagePrecedence dependency from DELETE_ONLY TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} +│ │ rule: "TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY" +│ │ +│ ├── • 9 elements transitioning toward ABSENT │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 3 (k-)} │ │ │ │ PUBLIC → WRITE_ONLY @@ -22,21 +39,110 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} │ │ │ rule: "secondary indexes containing column as key reach write-only before column" │ │ │ -│ │ └── • ColumnName:{DescID: 104 (t), Name: "k", ColumnID: 3 (k-)} +│ │ ├── • ColumnName:{DescID: 104 (t), Name: "k", ColumnID: 3 (k-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 3 (k-)} +│ │ │ rule: "column no longer public before dependents" +│ │ │ +│ │ ├── • Column:{DescID: 104 (t), ColumnID: 2 (j-)} +│ │ │ │ WRITE_ONLY → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 2 (j-)} +│ │ │ rule: "Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY" +│ │ │ +│ │ ├── • Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ │ WRITE_ONLY → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ rule: "Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 3 (k-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 3 (k-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ VALIDATED → DELETE_ONLY +│ │ │ │ +│ │ │ └── • PreviousStagePrecedence dependency from VALIDATED SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "SecondaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY" +│ │ │ +│ │ └── • IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} │ │ │ PUBLIC → ABSENT │ │ │ -│ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 104 (t), ColumnID: 3 (k-)} -│ │ rule: "column no longer public before dependents" +│ │ ├── • Precedence dependency from DELETE_ONLY SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ │ rule: "index no longer public before index name" +│ │ │ +│ │ └── • Precedence dependency from VALIDATED SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} +│ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 2 Mutation operations +│ └── • 10 Mutation operations │ │ │ ├── • MakePublicColumnWriteOnly │ │ ColumnID: 3 │ │ TableID: 104 │ │ -│ └── • SetColumnName -│ ColumnID: 3 -│ Name: crdb_internal_column_3_name_placeholder +│ ├── • SetColumnName +│ │ ColumnID: 3 +│ │ Name: crdb_internal_column_3_name_placeholder +│ │ TableID: 104 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 104 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4 +│ │ TableID: 104 +│ │ +│ ├── • MakeDeleteOnlyIndexWriteOnly +│ │ IndexID: 4 +│ │ TableID: 104 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 2 +│ │ TableID: 104 +│ │ +│ ├── • SetIndexName +│ │ IndexID: 2 +│ │ Name: crdb_internal_index_2_name_placeholder +│ │ TableID: 104 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 4 +│ │ IndexID: 2 +│ │ TableID: 104 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 3 +│ │ IndexID: 2 +│ │ Ordinal: 1 +│ │ TableID: 104 +│ │ +│ └── • RemoveColumnFromIndex +│ ColumnID: 1 +│ IndexID: 2 +│ Kind: 1 │ TableID: 104 │ ├── • PreCommitPhase @@ -54,15 +160,18 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ │ └── • PrimaryIndex:{DescID: 104 (t), IndexID: 3 (t_pkey+), ConstraintID: 2, TemporaryIndexID: 4 (crdb_internal_index_4_name_placeholder), SourceIndexID: 1 (t_pkey-)} │ │ │ BACKFILL_ONLY → ABSENT │ │ │ -│ │ ├── • 2 elements transitioning toward TRANSIENT_ABSENT +│ │ ├── • 3 elements transitioning toward TRANSIENT_ABSENT │ │ │ │ │ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 4 (crdb_internal_index_4_name_placeholder)} │ │ │ │ PUBLIC → ABSENT │ │ │ │ +│ │ │ ├── • IndexData:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ │ │ │ └── • TemporaryIndex:{DescID: 104 (t), IndexID: 4 (crdb_internal_index_4_name_placeholder), ConstraintID: 3, SourceIndexID: 1 (t_pkey-)} -│ │ │ DELETE_ONLY → ABSENT +│ │ │ WRITE_ONLY → ABSENT │ │ │ -│ │ ├── • 7 elements transitioning toward ABSENT +│ │ ├── • 11 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 3 (k-)} │ │ │ │ WRITE_ONLY → PUBLIC @@ -71,13 +180,25 @@ EXPLAIN (ddl, verbose) ALTER TABLE t DROP COLUMN k CASCADE; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 2 (j-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 4 (crdb_internal_idx_expr-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 3 (k-), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 104 (t), ColumnID: 1 (i), IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • SecondaryIndex:{DescID: 104 (t), IndexID: 2 (t_expr_k_idx-)} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ DELETE_ONLY → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexName:{DescID: 104 (t), Name: "t_expr_k_idx", IndexID: 2 (t_expr_k_idx-)} +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 104 (t), Name: "j", ColumnID: 2 (j-)} │ │ │ │ ABSENT → PUBLIC diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_table b/pkg/sql/schemachanger/testdata/explain_verbose/drop_table index 79e321537b4a..f84dcd169d55 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_table +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_table @@ -14,7 +14,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 27 elements transitioning toward ABSENT +│ ├── • 30 elements transitioning toward ABSENT │ │ │ │ │ ├── • Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} │ │ │ │ PUBLIC → ABSENT @@ -78,10 +78,19 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 1 (k-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (k-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} │ │ │ │ PUBLIC → ABSENT @@ -102,10 +111,19 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 2 (v-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (v-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} │ │ │ │ PUBLIC → ABSENT @@ -126,10 +144,28 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 3 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} │ │ │ │ PUBLIC → ABSENT @@ -153,10 +189,13 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column type dependents removed right before column type" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} │ │ │ │ PUBLIC → ABSENT @@ -168,10 +207,16 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -192,10 +237,16 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -215,11 +266,59 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 1 (k-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 107 (t-), ColumnID: 2 (v-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 107 (t-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ └── • IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ │ PUBLIC → ABSENT @@ -230,7 +329,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 22 Mutation operations +│ └── • 38 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 107 @@ -323,14 +422,84 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ DescriptorID: 107 │ │ User: root │ │ -│ └── • AssertColumnFamilyIsRemoved +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 107 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 107 +│ │ +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 3 +│ │ TableID: 107 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 107 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 107 +│ │ +│ ├── • AssertColumnFamilyIsRemoved +│ │ TableID: 107 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 3 +│ │ TableID: 107 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 107 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 107 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 107 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 3 +│ │ IndexID: 1 +│ │ TableID: 107 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ Kind: 2 +│ │ TableID: 107 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 2 +│ │ IndexID: 1 +│ │ Kind: 2 +│ │ Ordinal: 1 +│ │ TableID: 107 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 107 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 1 +│ │ TableID: 107 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 2 +│ │ TableID: 107 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 3 │ TableID: 107 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 27 elements transitioning toward ABSENT +│ │ ├── • 30 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Namespace:{DescID: 107 (t-), Name: "t", ReferencedDescID: 104 (db)} │ │ │ │ ABSENT → PUBLIC @@ -357,7 +526,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 1 (k-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "k", ColumnID: 1 (k-)} │ │ │ │ ABSENT → PUBLIC @@ -366,7 +535,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 2 (v-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "v", ColumnID: 2 (v-)} │ │ │ │ ABSENT → PUBLIC @@ -375,7 +544,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 3 (rowid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "rowid", ColumnID: 3 (rowid-)} │ │ │ │ ABSENT → PUBLIC @@ -384,13 +553,13 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnDefaultExpression:{DescID: 107 (t-), ColumnID: 3 (rowid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -399,7 +568,7 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 107 (t-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 107 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -407,8 +576,17 @@ EXPLAIN (ddl, verbose) DROP TABLE db.sc.t; │ │ │ ├── • ColumnType:{DescID: 107 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 3 (rowid-), IndexID: 1 (t_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 1 (k-), IndexID: 1 (t_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 107 (t-), ColumnID: 2 (v-), IndexID: 1 (t_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 107 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ └── • IndexName:{DescID: 107 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ │ ABSENT → PUBLIC diff --git a/pkg/sql/schemachanger/testdata/explain_verbose/drop_table_udf_default b/pkg/sql/schemachanger/testdata/explain_verbose/drop_table_udf_default index de475fcc38d1..a14e6666f7ac 100644 --- a/pkg/sql/schemachanger/testdata/explain_verbose/drop_table_udf_default +++ b/pkg/sql/schemachanger/testdata/explain_verbose/drop_table_udf_default @@ -11,7 +11,7 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ └── • Stage 1 of 1 in StatementPhase │ │ -│ ├── • 23 elements transitioning toward ABSENT +│ ├── • 25 elements transitioning toward ABSENT │ │ │ │ │ ├── • Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} │ │ │ │ PUBLIC → ABSENT @@ -66,10 +66,25 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ rule: "column type removed before column family" │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 1 (i-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • SameStagePrecedence dependency from ABSENT ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} +│ │ │ │ rule: "column constraint removed right before column reaches delete only" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 1 (i-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} │ │ │ │ PUBLIC → ABSENT @@ -90,16 +105,31 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent constraint" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent constraint" +│ │ │ │ +│ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 1 (i-)} +│ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 2 (b-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 2 (b-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnDefaultExpression:{DescID: 105 (t-), ColumnID: 2 (b-), ReferencedFunctionIDs: [104 (#104)]} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} │ │ │ │ PUBLIC → ABSENT @@ -132,10 +162,16 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ PUBLIC → ABSENT @@ -156,10 +192,16 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ rule: "column no longer public before dependents" │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ PUBLIC → WRITE_ONLY +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent column" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent column" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} +│ │ │ │ rule: "dependents removed before column" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} +│ │ │ rule: "dependents removed before column" │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ PUBLIC → ABSENT @@ -179,11 +221,44 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ └── • Precedence dependency from WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} │ │ │ rule: "column no longer public before dependents" │ │ │ +│ │ ├── • IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 1 (i-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ +│ │ ├── • IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} +│ │ │ │ PUBLIC → ABSENT +│ │ │ │ +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "descriptor dropped before dependent element removal" +│ │ │ │ +│ │ │ ├── • Precedence dependency from WRITE_ONLY Column:{DescID: 105 (t-), ColumnID: 2 (b-)} +│ │ │ │ rule: "column no longer public before dependents" +│ │ │ │ +│ │ │ └── • Precedence dependency from DELETE_ONLY PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} +│ │ │ rule: "index drop mutation visible before cleaning up index columns" +│ │ │ │ │ ├── • PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} -│ │ │ │ PUBLIC → VALIDATED +│ │ │ │ PUBLIC → ABSENT │ │ │ │ -│ │ │ └── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} -│ │ │ rule: "relation dropped before dependent index" +│ │ │ ├── • Precedence dependency from DROPPED Table:{DescID: 105 (t-)} +│ │ │ │ rule: "relation dropped before dependent index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ ├── • Precedence dependency from ABSENT IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} +│ │ │ │ rule: "dependents removed before index" +│ │ │ │ +│ │ │ └── • Precedence dependency from ABSENT IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} +│ │ │ rule: "dependents removed before index" │ │ │ │ │ └── • IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ │ PUBLIC → ABSENT @@ -194,7 +269,7 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ └── • Precedence dependency from VALIDATED PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} │ │ rule: "index no longer public before dependents, excluding columns" │ │ -│ └── • 20 Mutation operations +│ └── • 33 Mutation operations │ │ │ ├── • MarkDescriptorAsDropped │ │ DescriptorID: 105 @@ -281,14 +356,69 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ DescriptorID: 105 │ │ User: root │ │ -│ └── • AssertColumnFamilyIsRemoved +│ ├── • RemoveColumnNotNull +│ │ ColumnID: 1 +│ │ TableID: 105 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 2 +│ │ TableID: 105 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967295 +│ │ TableID: 105 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 4294967294 +│ │ TableID: 105 +│ │ +│ ├── • AssertColumnFamilyIsRemoved +│ │ TableID: 105 +│ │ +│ ├── • MakeWriteOnlyColumnDeleteOnly +│ │ ColumnID: 1 +│ │ TableID: 105 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967295 +│ │ TableID: 105 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 4294967294 +│ │ TableID: 105 +│ │ +│ ├── • MakeWriteOnlyIndexDeleteOnly +│ │ IndexID: 1 +│ │ TableID: 105 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 1 +│ │ IndexID: 1 +│ │ TableID: 105 +│ │ +│ ├── • RemoveColumnFromIndex +│ │ ColumnID: 2 +│ │ IndexID: 1 +│ │ Kind: 2 +│ │ TableID: 105 +│ │ +│ ├── • MakeIndexAbsent +│ │ IndexID: 1 +│ │ TableID: 105 +│ │ +│ ├── • MakeDeleteOnlyColumnAbsent +│ │ ColumnID: 1 +│ │ TableID: 105 +│ │ +│ └── • MakeDeleteOnlyColumnAbsent +│ ColumnID: 2 │ TableID: 105 │ ├── • PreCommitPhase │ │ │ ├── • Stage 1 of 2 in PreCommitPhase │ │ │ -│ │ ├── • 23 elements transitioning toward ABSENT +│ │ ├── • 25 elements transitioning toward ABSENT │ │ │ │ │ │ │ ├── • Namespace:{DescID: 105 (t-), Name: "t", ReferencedDescID: 100 (defaultdb)} │ │ │ │ ABSENT → PUBLIC @@ -312,7 +442,7 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 1 (i-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "i", ColumnID: 1 (i-)} │ │ │ │ ABSENT → PUBLIC @@ -321,10 +451,10 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnNotNull:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 0} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 2 (b-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "b", ColumnID: 2 (b-)} │ │ │ │ ABSENT → PUBLIC @@ -336,7 +466,7 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "crdb_internal_mvcc_timestamp", ColumnID: 4294967295 (crdb_internal_mvcc_timestamp-)} │ │ │ │ ABSENT → PUBLIC @@ -345,7 +475,7 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • Column:{DescID: 105 (t-), ColumnID: 4294967294 (tableoid-)} -│ │ │ │ WRITE_ONLY → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ ├── • ColumnName:{DescID: 105 (t-), Name: "tableoid", ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC @@ -353,8 +483,14 @@ EXPLAIN (ddl, verbose) DROP TABLE t; │ │ │ ├── • ColumnType:{DescID: 105 (t-), ColumnFamilyID: 0 (primary-), ColumnID: 4294967294 (tableoid-)} │ │ │ │ ABSENT → PUBLIC │ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 105 (t-), ColumnID: 1 (i-), IndexID: 1 (t_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ +│ │ │ ├── • IndexColumn:{DescID: 105 (t-), ColumnID: 2 (b-), IndexID: 1 (t_pkey-)} +│ │ │ │ ABSENT → PUBLIC +│ │ │ │ │ │ │ ├── • PrimaryIndex:{DescID: 105 (t-), IndexID: 1 (t_pkey-), ConstraintID: 1} -│ │ │ │ VALIDATED → PUBLIC +│ │ │ │ ABSENT → PUBLIC │ │ │ │ │ │ │ └── • IndexName:{DescID: 105 (t-), Name: "t_pkey", IndexID: 1 (t_pkey-)} │ │ │ ABSENT → PUBLIC From a2026619cdfde496ec674a25d581d256acff16ec Mon Sep 17 00:00:00 2001 From: Faizan Qazi Date: Mon, 5 Jun 2023 11:57:07 -0400 Subject: [PATCH 2/2] sql/schemachanger: disable two version invariant for added descriptors Previously, the two version invariant was enforced for all non-dropped descriptors. When creating new descriptors if they are going to be decomposed into individual elements, then similar logic needs to skip added descriptors. To address this, this patch disables these rules for added descriptors. Epic: none Release note: None --- .../internal/rules/current/dep_two_version.go | 2 +- .../scplan/internal/rules/current/helpers.go | 17 + .../internal/rules/current/testdata/deprules | 376 +++++++++--------- 3 files changed, 206 insertions(+), 189 deletions(-) diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/dep_two_version.go b/pkg/sql/schemachanger/scplan/internal/rules/current/dep_two_version.go index 0a804dbe1b07..a10277da0ee4 100644 --- a/pkg/sql/schemachanger/scplan/internal/rules/current/dep_two_version.go +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/dep_two_version.go @@ -69,7 +69,7 @@ func init() { from.Target.AttrEq(screl.TargetStatus, targetStatus.Status()), from.Node.AttrEq(screl.CurrentStatus, t.From()), to.Node.AttrEq(screl.CurrentStatus, t.To()), - descriptorIsNotBeingDropped(from.El), + descriptorIsNotBeingAddedOrDropped(from.El), } if len(prePrevStatuses) > 0 { clauses = append(clauses, diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/helpers.go b/pkg/sql/schemachanger/scplan/internal/rules/current/helpers.go index 5a6110e26612..ea7190c370f2 100644 --- a/pkg/sql/schemachanger/scplan/internal/rules/current/helpers.go +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/helpers.go @@ -44,6 +44,23 @@ var descriptorIsNotBeingDropped = screl.Schema.DefNotJoin1( }, ) +// descriptorIsNotBeingAddedOrDropped creates a clause which leads to the outer clause +// failing to unify if the passed element is part of a descriptor and +// that descriptor is being added or dropped. +var descriptorIsNotBeingAddedOrDropped = screl.Schema.DefNotJoin1( + "descriptorIsNotBeingAddedOrDropped"+rulesVersion, "element", func( + element rel.Var, + ) rel.Clauses { + descriptor := rules.MkNodeVars("descriptor") + return rel.Clauses{ + descriptor.TypeFilter(rulesVersionKey, isDescriptor), + descriptor.JoinTarget(), + rules.JoinOnDescIDUntyped(descriptor.El, element, "id"), + descriptor.TargetStatus(scpb.ToPublic, scpb.ToAbsent), + } + }, +) + // isDescriptor returns true for a descriptor-element, i.e. an element which // owns its corresponding descriptor. func isDescriptor(e scpb.Element) bool { diff --git a/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules b/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules index 4b85021f79f4..d0a79ca8be55 100644 --- a/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules +++ b/pkg/sql/schemachanger/scplan/internal/rules/current/testdata/deprules @@ -29,7 +29,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -45,7 +45,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -62,7 +62,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -98,7 +98,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -114,7 +114,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -130,7 +130,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -165,7 +165,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: PUBLIC->WRITE_ONLY' @@ -181,7 +181,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -197,7 +197,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold only single transition in statement phase: WRITE_ONLY->DELETE_ONLY' @@ -232,7 +232,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY' @@ -248,7 +248,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->PUBLIC' @@ -264,7 +264,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold only single transition in statement phase: DELETE_ONLY->WRITE_ONLY' @@ -299,7 +299,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -315,7 +315,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -332,7 +332,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -368,7 +368,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -384,7 +384,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -400,7 +400,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -603,7 +603,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -619,7 +619,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -636,7 +636,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -672,7 +672,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -688,7 +688,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -704,7 +704,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -754,7 +754,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILL_ONLY->DELETE_ONLY' @@ -770,7 +770,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' @@ -786,7 +786,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_DELETE_ONLY_BACKFILLED_TRANSIENT_BACKFILLED_BACKFILL_ONLY_TRANSIENT_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -803,7 +803,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: MERGE_ONLY->WRITE_ONLY' @@ -819,7 +819,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -835,7 +835,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_ABSENT->ABSENT' @@ -851,7 +851,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_ABSENT - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_BACKFILLED->DELETE_ONLY' @@ -867,7 +867,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_BACKFILL_ONLY->DELETE_ONLY' @@ -883,7 +883,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->DELETE_ONLY' @@ -899,7 +899,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_MERGED->WRITE_ONLY' @@ -915,7 +915,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_MERGE_ONLY->WRITE_ONLY' @@ -931,7 +931,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_VALIDATED->VALIDATED' @@ -947,7 +947,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_VALIDATED - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_WRITE_ONLY->WRITE_ONLY' @@ -963,7 +963,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY' @@ -979,7 +979,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -996,7 +996,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_VALIDATED_TRANSIENT_WRITE_ONLY_MERGE_ONLY_TRANSIENT_MERGE_ONLY_MERGED_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1033,7 +1033,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -1049,7 +1049,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -1065,7 +1065,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -1081,7 +1081,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -1097,7 +1097,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -1113,7 +1113,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -1129,7 +1129,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -1145,7 +1145,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' @@ -1180,7 +1180,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -1196,7 +1196,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -1212,7 +1212,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -1228,7 +1228,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -1244,7 +1244,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -1260,7 +1260,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: PUBLIC->TRANSIENT_VALIDATED' @@ -1276,7 +1276,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = TRANSIENT_VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_BACKFILLED->TRANSIENT_DELETE_ONLY' @@ -1292,7 +1292,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILLED - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_BACKFILL_ONLY->TRANSIENT_DELETE_ONLY' @@ -1308,7 +1308,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILL_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->TRANSIENT_ABSENT' @@ -1324,7 +1324,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_BACKFILLED_TRANSIENT_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1341,7 +1341,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGED - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_MERGE_ONLY->TRANSIENT_WRITE_ONLY' @@ -1357,7 +1357,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_VALIDATED->TRANSIENT_WRITE_ONLY' @@ -1373,7 +1373,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_VALIDATED - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_WRITE_ONLY->TRANSIENT_DELETE_ONLY' @@ -1389,7 +1389,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED_TRANSIENT_MERGE_ONLY_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1406,7 +1406,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -1422,7 +1422,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' @@ -1453,7 +1453,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILL_ONLY->DELETE_ONLY' @@ -1469,7 +1469,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' @@ -1485,7 +1485,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_BACKFILLED_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1502,7 +1502,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: MERGE_ONLY->WRITE_ONLY' @@ -1518,7 +1518,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -1534,7 +1534,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY' @@ -1550,7 +1550,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -1566,7 +1566,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_VALIDATED_MERGE_ONLY_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1602,7 +1602,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -1618,7 +1618,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -1634,7 +1634,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -1650,7 +1650,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -1666,7 +1666,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -1682,7 +1682,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -1698,7 +1698,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -1714,7 +1714,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' @@ -1781,7 +1781,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_DELETE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1798,7 +1798,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_ABSENT - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->DELETE_ONLY' @@ -1814,7 +1814,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -1830,7 +1830,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: ABSENT->DELETE_ONLY' @@ -1846,7 +1846,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY' @@ -1862,7 +1862,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->TRANSIENT_ABSENT' @@ -1878,7 +1878,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: WRITE_ONLY->TRANSIENT_DELETE_ONLY' @@ -1894,7 +1894,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -1910,7 +1910,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -1926,7 +1926,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -1943,7 +1943,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -1979,7 +1979,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -1995,7 +1995,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -2011,7 +2011,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -3923,7 +3923,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -3939,7 +3939,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -3956,7 +3956,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -3992,7 +3992,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -4008,7 +4008,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -4024,7 +4024,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'CheckConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -4059,7 +4059,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: PUBLIC->WRITE_ONLY' @@ -4075,7 +4075,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -4091,7 +4091,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to ABSENT uphold only single transition in statement phase: WRITE_ONLY->DELETE_ONLY' @@ -4126,7 +4126,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY' @@ -4142,7 +4142,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->PUBLIC' @@ -4158,7 +4158,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Column transitions to PUBLIC uphold only single transition in statement phase: DELETE_ONLY->WRITE_ONLY' @@ -4193,7 +4193,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -4209,7 +4209,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -4226,7 +4226,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -4262,7 +4262,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -4278,7 +4278,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -4294,7 +4294,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ColumnNotNull transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -4497,7 +4497,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -4513,7 +4513,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -4530,7 +4530,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -4566,7 +4566,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -4582,7 +4582,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -4598,7 +4598,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'ForeignKeyConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED' @@ -4648,7 +4648,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILL_ONLY->DELETE_ONLY' @@ -4664,7 +4664,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' @@ -4680,7 +4680,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_DELETE_ONLY_BACKFILLED_TRANSIENT_BACKFILLED_BACKFILL_ONLY_TRANSIENT_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -4697,7 +4697,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: MERGE_ONLY->WRITE_ONLY' @@ -4713,7 +4713,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -4729,7 +4729,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_ABSENT->ABSENT' @@ -4745,7 +4745,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_ABSENT - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_BACKFILLED->DELETE_ONLY' @@ -4761,7 +4761,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_BACKFILL_ONLY->DELETE_ONLY' @@ -4777,7 +4777,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->DELETE_ONLY' @@ -4793,7 +4793,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_MERGED->WRITE_ONLY' @@ -4809,7 +4809,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_MERGE_ONLY->WRITE_ONLY' @@ -4825,7 +4825,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_VALIDATED->VALIDATED' @@ -4841,7 +4841,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_VALIDATED - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_WRITE_ONLY->WRITE_ONLY' @@ -4857,7 +4857,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY' @@ -4873,7 +4873,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -4890,7 +4890,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_VALIDATED_TRANSIENT_WRITE_ONLY_MERGE_ONLY_TRANSIENT_MERGE_ONLY_MERGED_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -4927,7 +4927,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -4943,7 +4943,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -4959,7 +4959,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -4975,7 +4975,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -4991,7 +4991,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -5007,7 +5007,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -5023,7 +5023,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -5039,7 +5039,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' @@ -5074,7 +5074,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -5090,7 +5090,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -5106,7 +5106,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -5122,7 +5122,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -5138,7 +5138,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -5154,7 +5154,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: PUBLIC->TRANSIENT_VALIDATED' @@ -5170,7 +5170,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = TRANSIENT_VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_BACKFILLED->TRANSIENT_DELETE_ONLY' @@ -5186,7 +5186,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILLED - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_BACKFILL_ONLY->TRANSIENT_DELETE_ONLY' @@ -5202,7 +5202,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_BACKFILL_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->TRANSIENT_ABSENT' @@ -5218,7 +5218,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_BACKFILLED_TRANSIENT_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5235,7 +5235,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGED - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_MERGE_ONLY->TRANSIENT_WRITE_ONLY' @@ -5251,7 +5251,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_MERGE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_VALIDATED->TRANSIENT_WRITE_ONLY' @@ -5267,7 +5267,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_VALIDATED - $next-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_WRITE_ONLY->TRANSIENT_DELETE_ONLY' @@ -5283,7 +5283,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_WRITE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_VALIDATED_TRANSIENT_MERGE_ONLY_TRANSIENT_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5300,7 +5300,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'PrimaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -5316,7 +5316,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'Schema transitions to PUBLIC uphold only single transition in statement phase: DESCRIPTOR_ADDED->PUBLIC' @@ -5347,7 +5347,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: BACKFILL_ONLY->DELETE_ONLY' @@ -5363,7 +5363,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: DELETE_ONLY->ABSENT' @@ -5379,7 +5379,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_BACKFILLED_BACKFILL_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5396,7 +5396,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: MERGE_ONLY->WRITE_ONLY' @@ -5412,7 +5412,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -5428,7 +5428,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: VALIDATED->WRITE_ONLY' @@ -5444,7 +5444,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -5460,7 +5460,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_VALIDATED_MERGE_ONLY_MERGED($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5496,7 +5496,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = BACKFILL_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILLED->DELETE_ONLY' @@ -5512,7 +5512,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILLED - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: BACKFILL_ONLY->BACKFILLED' @@ -5528,7 +5528,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = BACKFILL_ONLY - $next-Node[CurrentStatus] = BACKFILLED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: DELETE_ONLY->MERGE_ONLY' @@ -5544,7 +5544,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = MERGE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: MERGED->WRITE_ONLY' @@ -5560,7 +5560,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGED - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: MERGE_ONLY->MERGED' @@ -5576,7 +5576,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = MERGE_ONLY - $next-Node[CurrentStatus] = MERGED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -5592,7 +5592,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -5608,7 +5608,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'SecondaryIndex transitions to PUBLIC uphold only single transition in statement phase: BACKFILL_ONLY->BACKFILLED' @@ -5675,7 +5675,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_TRANSIENT_DELETE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5692,7 +5692,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_ABSENT - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->DELETE_ONLY' @@ -5708,7 +5708,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to ABSENT uphold 2-version invariant: WRITE_ONLY->DELETE_ONLY' @@ -5724,7 +5724,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: ABSENT->DELETE_ONLY' @@ -5740,7 +5740,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: DELETE_ONLY->WRITE_ONLY' @@ -5756,7 +5756,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = DELETE_ONLY - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: TRANSIENT_DELETE_ONLY->TRANSIENT_ABSENT' @@ -5772,7 +5772,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'TemporaryIndex transitions to TRANSIENT_ABSENT uphold 2-version invariant: WRITE_ONLY->TRANSIENT_DELETE_ONLY' @@ -5788,7 +5788,7 @@ deprules - $prev-Target[TargetStatus] = TRANSIENT_ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = TRANSIENT_DELETE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold 2-version invariant: PUBLIC->VALIDATED' @@ -5804,7 +5804,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = PUBLIC - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold 2-version invariant: VALIDATED->ABSENT' @@ -5820,7 +5820,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = ABSENT - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - nodeNotExistsWithStatusIn_WRITE_ONLY($prev-Target) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) @@ -5837,7 +5837,7 @@ deprules - $prev-Target[TargetStatus] = ABSENT - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to ABSENT uphold only single transition in statement phase: VALIDATED->ABSENT' @@ -5873,7 +5873,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = ABSENT - $next-Node[CurrentStatus] = WRITE_ONLY - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: VALIDATED->PUBLIC' @@ -5889,7 +5889,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = VALIDATED - $next-Node[CurrentStatus] = PUBLIC - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold 2-version invariant: WRITE_ONLY->VALIDATED' @@ -5905,7 +5905,7 @@ deprules - $prev-Target[TargetStatus] = PUBLIC - $prev-Node[CurrentStatus] = WRITE_ONLY - $next-Node[CurrentStatus] = VALIDATED - - descriptorIsNotBeingDropped-23.2($prev) + - descriptorIsNotBeingAddedOrDropped-23.2($prev) - joinTargetNode($prev, $prev-Target, $prev-Node) - joinTargetNode($next, $next-Target, $next-Node) - name: 'UniqueWithoutIndexConstraint transitions to PUBLIC uphold only single transition in statement phase: WRITE_ONLY->VALIDATED'