Closed thedarkknight197 closed 6 months ago
Hello @farhanW3, can you take a look into this? Our user here is having trouble with the existing database with Engine.
I have updated with full docker-compose.yml
@thedarkknight197
Looks like Postgres version 13 (which you are using) has a different syntax for creating triggers:
postgres:
image: postgres:13.5
Our trigger creation syntax is, CREATE OR REPLACE ...
which is supported >= Postgres 14.
If you can update the Postgres Version and try it out. We will also, make sure to update our docs and reflect this requirement (if not there already)
@thedarkknight197
Looks like Postgres version 13 (which you are using) has a different syntax for creating triggers:
postgres: image: postgres:13.5
Our trigger creation syntax is,
CREATE OR REPLACE ...
which is supported >= Postgres 14.If you can update the Postgres Version and try it out. We will also, make sure to update our docs and reflect this requirement (if not there already)
I will update our automated script too for deploying locally.
@thedarkknight197 Looks like Postgres version 13 (which you are using) has a different syntax for creating triggers:
postgres: image: postgres:13.5
Our trigger creation syntax is,
CREATE OR REPLACE ...
which is supported >= Postgres 14. If you can update the Postgres Version and try it out. We will also, make sure to update our docs and reflect this requirement (if not there already)I will update our automated script too for deploying locally.
@warengonzaga Can't update postgres 13.5 to 14, on db starting i receive this error:
PostgreSQL Database directory appears to contain a database; Skipping initialization
2024-04-20T12:11:14.066288941Z
2024-04-20T12:11:14.077212000Z 2024-04-20 12:11:14.077 UTC [1] FATAL: database files are incompatible with server
2024-04-20T12:11:14.077235099Z 2024-04-20 12:11:14.077 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 13, which is not compatible with this version 14.11 (Debian 14.11-1.pgdg120+2).
Hey @thedarkknight197
looks, like migration is failing and it's because the data directory is not compatible with v15. if you clear the volume attached for postgres, this will go away, but it will also remove everything. Not sure on what data you have on Postgres & whether it's important.
There are multiple ways of migrating, you might have to read up choose what works best for you. One of them is, you can create back-ups of your db & restore it once you have migrated to newer version
But, if you can do a clean install + run, everything, should work smoothly.
let me know.
Dockercompose
My docker-compose.yml:
Error
The db is a postgres docker on the same docker-compose
first run
second run