Closed CodingDoug closed 1 year ago
A UNIQUE
constraint is returned as an index when getTableIndexes
is called.
Then it is passed to dumpTableIndexes
, dumpIndex
and getIndex
.
The last function does a SQL query to fetch the index data, but the query returns null
, which leads to a NULL;
statement being print in the dump.
Create a new database:
Create a new table with a unique column and dump it:
See invalid
NULL
in the output, as well as missingUNIQUE
in the schema:This does not happen for unique indexes added separately.