mirror of https://github.com/Fabio286/antares.git
fix: unique keys not recognized in table settings on some MariaDB versions
This commit is contained in:
parent
53a71d55c5
commit
446199827b
|
@ -689,11 +689,11 @@ export class MySQLClient extends AntaresCore {
|
|||
|
||||
return rows.map(row => {
|
||||
return {
|
||||
unique: !row.Non_unique,
|
||||
unique: !Number(row.Non_unique),
|
||||
name: row.Key_name,
|
||||
column: row.Column_name,
|
||||
indexType: row.Index_type,
|
||||
type: row.Key_name === 'PRIMARY' ? 'PRIMARY' : !row.Non_unique ? 'UNIQUE' : row.Index_type === 'FULLTEXT' ? 'FULLTEXT' : 'INDEX',
|
||||
type: row.Key_name === 'PRIMARY' ? 'PRIMARY' : !Number(row.Non_unique) ? 'UNIQUE' : row.Index_type === 'FULLTEXT' ? 'FULLTEXT' : 'INDEX',
|
||||
cardinality: row.Cardinality,
|
||||
comment: row.Comment,
|
||||
indexComment: row.Index_comment
|
||||
|
|
Loading…
Reference in New Issue