fix(MySQL): missing exported values for DEFAULT_GENERATED table fields, fixes #854

This commit is contained in:
Fabio Di Stasio 2024-10-01 18:08:58 +02:00
parent 76c8cd1beb
commit 2cda4a1fa1
1 changed files with 1 additions and 1 deletions

View File

@ -663,7 +663,7 @@ export class MySQLClient extends BaseClient {
charset: field.CHARACTER_SET_NAME, charset: field.CHARACTER_SET_NAME,
collation: field.COLLATION_NAME, collation: field.COLLATION_NAME,
autoIncrement: field.EXTRA.includes('auto_increment'), autoIncrement: field.EXTRA.includes('auto_increment'),
generated: field.EXTRA.toLowerCase().includes('generated'), generated: ['VIRTUAL GENERATED', 'VIRTUAL STORED'].includes(field.EXTRA),
onUpdate: field.EXTRA.toLowerCase().includes('on update') onUpdate: field.EXTRA.toLowerCase().includes('on update')
? field.EXTRA.substr(field.EXTRA.indexOf('on update') + 9, field.EXTRA.length).trim() ? field.EXTRA.substr(field.EXTRA.indexOf('on update') + 9, field.EXTRA.length).trim()
: '', : '',