Open jbmolle opened 1 year ago
Hi, can you post the exact commands that you used to create the psql 15 db?
Hi, I've just created a pull request to solve the bug. The problem is coming from the sequence resynchronization. In Postgres 15 you don't have access to public schema per default so I've created a nextcloud schema for my nextcloud user (which is the default schema). So my column_default is nextval('oc_xxxx_id_seq'::regclass) but the sequenceName is nextcloud.oc_xxx_id_seq and the WHERE clause does not work.
I've just created a pull request to solve the bug.
Where?
In Postgres 15 you don't have access to public schema per default so I've created a nextcloud schema for my nextcloud user (which is the default schema).
Indeed you need to grant access to the public schema which is documented here: https://docs.nextcloud.com/server/latest/admin_manual/configuration_database/linux_database_configuration.html#postgresql-database
Thanks for the link, I didn't see it. If we don't use the public schema but instead the username schema, Nextcloud works the same (as username schema is the default). For the sequence migration, we just need to use getShortestName and getNamespaceName instead of getName.
⚠️ This issue respects the following points: ⚠️
Bug description
The migration from MariaDB to Postgresql 15 fails. resynchronizeDatabaseSequences function fails with an error nextcloud.xxx_id_seq', (SELECT MAX() FROM ))
Steps to reproduce
Expected behavior
The migration should end without any problem and the database configuration of Nextcloud should point to the new Postgres database.
Installation method
Other Community project
Operating system
None
PHP engine version
None
Web server
None
Database engine version
PostgreSQL
Is this bug present after an update or on a fresh install?
None
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
Configuration report
No response
List of activated Apps
Nextcloud Signing status
No response
Nextcloud Logs
No response
Additional info
No response