12 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
1
answer
128
views
Error: column "displayUsername" of relation "users" does not exist in better-auth 1.3.6 and 1.3.7
I am getting the following error when I try to update a username in better-auth from a sveltekit client
# SERVER_ERROR: error: column "displayUsername" of relation "users" does ...
0
votes
1
answer
535
views
Can node-pg-migrate target a specific schema?
I have a node.js project which uses node-pg-migrate to manage the database in the public schema.
I have a second project, and want to use node-pg-migrate to manage an additional schema within the same ...
0
votes
1
answer
1k
views
How to specify the migration folder path in node-pg-migrate?
I'm using the package node-pg-migrate to control my migrations, but i can't specify the folder i want to create the migration file in CLI.
When i run node-pg-migrate create my first migration --...
0
votes
0
answers
518
views
How do I run a PostgreSQL container using docker-compose with startup files that depends on .env values, then running node-pg-migrate?
I want the following flow.
PostgreSQL runs startup script with the values from .env file
PostgreSQL runs successfully
App runs successfully
Run migration commands. I have already created the scripts ...
0
votes
1
answer
575
views
ENOENT error with child_process spawn referencing a plaintext file meant to run node
I'm trying to recreate the migrate function in this codebase: https://codesandbox.io/s/e9fykv?file=/migrations/migrate.ts.
The relevant files in that codebase, for this question, are the following: &...
3
votes
1
answer
13k
views
pg_try_advisory_lock and pg_advisory_unlock always return false
I have a node.js app that uses PostgreSQL as a database.
When I try to run a migration file (using node-pg-migrate package), I keep getting an error: Another migration is already running.
Below is the ...
2
votes
1
answer
609
views
How to define "INT GENERATED ALWAYS AS IDENTITY" column with node-pg-migrate?
How do I define a migration file using node-pg-migrate for the below table
CREATE TABLE color (
color_id INT GENERATED ALWAYS AS IDENTITY,
color_name VARCHAR NOT NULL
);
There seems to be no ...
2
votes
1
answer
505
views
node-pg-migrate doesn't use config.json file
I'm passing the --config-file flag but it just wont read the thing, do I really need to install a package for something as simple as reading a configuration file? am I doing something wrong?, I run it ...
1
vote
3
answers
2k
views
node-pg-migration not reading .env file despite having dotenv installed
I am using node-pg-migrate and would like the db name, password and schema to come from the .env file as opposed to a config file. The .env file is not being used as using the default database.
Could ...
0
votes
1
answer
2k
views
Fails with preceeding/existing migrations
When creating a second migration and attempting to migrate up to add it, the task fails because the first migration was already run. It seems to be running (and failing) rather than skipping ...
3
votes
2
answers
11k
views
Run Postgres migration with Docker/Docker compose
I am pretty new to this whole subject, so excuse me if those are silly questions. I want to run unit tests in Docker containers like so:
Start up a Postgres container with no tables/data
Run the DB ...
3
votes
2
answers
4k
views
How do I insert records in a node-pg-migrate migration?
I'm trying to use node-pg-migrate to handle migrations for an ExpressJS app. I can translate most of the SQL dump into pgm.func() type calls, but I can't see any method for handling actual INSERT ...