occ upgrade fails wiith : An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1 no such column: \"-1\" - should this be a string literal in single-quotes?
Using pkg version on FreeBSD
Steps to reproduce
SQLite used as database
Installl nextcloud-php82-28.0.4
run pkg upgrade to update to 29.0.1
run occ upgrade
On another system I see the same error when updating from 28.0.3 to 28.0.6 and in nextcloud.log it reports the following query for the error:
SELECT t.name AS table_name,\n p.*\n FROM sqlite_master t\n JOIN pragma_foreign_key_list (t.name) p\n ON p.\"seq\" != \"-1\" WHERE t.type = 'table' AND t.name NOT IN ('geometry_columns', 'spatial_ref_sys', 'sqlite_sequence') ORDER BY t.name, p.id DESC, p.seq",[],[],null]},{"fi le":"/www/sites/vanderzwan/nextcloud/3rdparty/doctrine/dbal/src/Schema/SqliteSchemaManager.php","line":763,"function":"executeQuery","class":"OC\\DB\\Connection","type":"->","args":[" SELECT t .name AS table_name,\n p.*\n FROM sqlite_master t\n JOIN pragma_foreign_key_list(t.name) p\n ON p.\"seq\" != \"-1\" WHERE t.type = 'table' AND t .name NOT IN ('geometry_columns', 'spatial_ref_sys', 'sqlite_sequence') ORDER BY t.name, p.id DESC, p.seq
Expected behavior
occ upgrade completed without database exceptions
Installation method
None
Nextcloud Server version
29
Operating system
Other
PHP engine version
PHP 8.2
Web server
Apache (supported)
Database engine version
SQlite
Is this bug present after an update or on a fresh install?
Updated from a MINOR version (ex. 22.1 to 22.2)
Are you using the Nextcloud Server Encryption module?
⚠️ This issue respects the following points: ⚠️
Bug description
occ upgrade fails wiith : An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1 no such column: \"-1\" - should this be a string literal in single-quotes?
Using pkg version on FreeBSD
Steps to reproduce
SQLite used as database
On another system I see the same error when updating from 28.0.3 to 28.0.6 and in nextcloud.log it reports the following query for the error:
SELECT t.name AS table_name,\n p.*\n FROM sqlite_master t\n JOIN pragma_foreign_key_list (t.name) p\n ON p.\"seq\" != \"-1\" WHERE t.type = 'table' AND t.name NOT IN ('geometry_columns', 'spatial_ref_sys', 'sqlite_sequence') ORDER BY t.name, p.id DESC, p.seq",[],[],null]},{"fi le":"/www/sites/vanderzwan/nextcloud/3rdparty/doctrine/dbal/src/Schema/SqliteSchemaManager.php","line":763,"function":"executeQuery","class":"OC\\DB\\Connection","type":"->","args":[" SELECT t .name AS table_name,\n p.*\n FROM sqlite_master t\n JOIN pragma_foreign_key_list(t.name) p\n ON p.\"seq\" != \"-1\" WHERE t.type = 'table' AND t .name NOT IN ('geometry_columns', 'spatial_ref_sys', 'sqlite_sequence') ORDER BY t.name, p.id DESC, p.seq
Expected behavior
occ upgrade completed without database exceptions
Installation method
None
Nextcloud Server version
29
Operating system
Other
PHP engine version
PHP 8.2
Web server
Apache (supported)
Database engine version
SQlite
Is this bug present after an update or on a fresh install?
Updated from a MINOR version (ex. 22.1 to 22.2)
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
No response
Nextcloud Logs
No response
Additional info
No response