Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
chore: skip unsupported indexes (#8337)
rebeliceba089fb9d377
diff --git a/backend/api/v1/schema_design_transformer.go b/backend/api/v1/schema_design_transformer.goindex 91b4611b3e..7b42e3e391 100644--- a/backend/api/v1/schema_design_transformer.go+++ b/backend/api/v1/schema_design_transformer.go@@ -160,6 +160,19 @@ type tableState struct {foreignKeys map[string]*foreignKeyState}+func (t *tableState) removeUnsupportedIndex() {+ unsupported := []string{}+ for name, index := range t.indexes {+ if index.primary {+ continue+ }+ unsupported = append(unsupported, name)+ }+ for _, name := range unsupported {+ delete(t.indexes, name)+ }+}+func (t *tableState) toString(buf *strings.Builder) error {if _, err := buf.WriteString(fmt.Sprintf("CREATE TABLE `%s` (\n ", t.name)); err != nil {return err@@ -183,6 +196,7 @@ func (t *tableState) toString(buf *strings.Builder) error {}indexes := []*indexState{}+ t.removeUnsupportedIndex()for _, index := range t.indexes {indexes = append(indexes, index)}