diff --git a/pkg/sql/catalog/bootstrap/bootstrap_test.go b/pkg/sql/catalog/bootstrap/bootstrap_test.go index e33afc642dc..f4e04aa9dc5 100644 --- a/pkg/sql/catalog/bootstrap/bootstrap_test.go +++ b/pkg/sql/catalog/bootstrap/bootstrap_test.go @@ -98,11 +98,11 @@ func TestRoundTripInitialValuesStringRepresentation(t *testing.T) { roundTripInitialValuesStringRepresentation(t, 0 /* tenantID */) }) t.Run("tenant", func(t *testing.T) { - const dummyTenantID = 54321 + const dummyTenantID = 109 roundTripInitialValuesStringRepresentation(t, dummyTenantID) }) t.Run("tenants", func(t *testing.T) { - const dummyTenantID1, dummyTenantID2 = 54321, 12345 + const dummyTenantID1, dummyTenantID2 = 109, 255 require.Equal(t, InitialValuesToString(makeMetadataSchema(dummyTenantID1)), InitialValuesToString(makeMetadataSchema(dummyTenantID2)), diff --git a/pkg/sql/catalog/bootstrap/metadata.go b/pkg/sql/catalog/bootstrap/metadata.go index 6da5e5e4ad9..8e84c1eaa9c 100644 --- a/pkg/sql/catalog/bootstrap/metadata.go +++ b/pkg/sql/catalog/bootstrap/metadata.go @@ -321,7 +321,7 @@ func InitialValuesFromString( } // Add back the filtered out tenant end key. if !codec.ForSystemTenant() { - splits = append(splits, roachpb.RKey(p.PrefixEnd())) + splits = append(splits, roachpb.RKey(codec.TenantEndKey())) } return kvs, splits, nil }