Add AUTOINCREMENT to SqliteCompat PRIMARY KEY for SQLite compatibility
API CI/CD / Validate (composer + pint) (push) Successful in 2m6s
API CI/CD / Test (PHPUnit) (push) Failing after 2m27s
API CI/CD / Build frontend assets (push) Successful in 2m14s
API CI/CD / Security audit (push) Successful in 32s
API CI/CD / Deploy to shared hosting (PHP) (push) Has been skipped
API CI/CD / Validate (composer + pint) (push) Successful in 2m6s
API CI/CD / Test (PHPUnit) (push) Failing after 2m27s
API CI/CD / Build frontend assets (push) Successful in 2m14s
API CI/CD / Security audit (push) Successful in 32s
API CI/CD / Deploy to shared hosting (PHP) (push) Has been skipped
This commit is contained in:
@@ -36,8 +36,8 @@ class SqliteCompat
|
||||
|
||||
// Promote `id` column to PRIMARY KEY if not already.
|
||||
$sql = preg_replace(
|
||||
'/`id`\\s+integer\\s+NOT NULL/i',
|
||||
'`id` integer PRIMARY KEY NOT NULL',
|
||||
'/`id`\\s+integer\\s+NOT\\s*NULL/i',
|
||||
'`id` integer PRIMARY KEY AUTOINCREMENT NOT NULL',
|
||||
$sql,
|
||||
1
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user