New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dirty database version 1. Fix and force version
and error: can't read limit argument N
#1059
Comments
I am also getting an issue similar to this. Schema file CREATE TABLE IF NOT EXISTS movies (
id bigserial PRIMARY KEY,
created_at timestamp(0) with time zone NOT NULL DEFAULT NOW(),
title text NOT NULL,
year integer NOT NULL,
runtime integer NOT NULL,
genres text[] NOT NULL,
version integer NOT NULL DEFAULT 1
); |
@Delta456 hi, you should use force and up commands separately:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the Bug
A clear and concise description of what the bug is.
Steps to Reproduce
Steps to reproduce the behavior:
migrate -path=./migrations -database=$CHESS_DB_DSN up
error: migration failed: syntax error at or near ")"
Expected Behavior
to migrate
Migrate Version
e.g. v3.4.0
Obtained by running:
migrate -version
:v4.17.0
Loaded Source Drivers
e.g. s3, github, go-bindata, gcs, file
Obtained by running:
migrate -help
Loaded Database Drivers
e.g. spanner, stub, clickhouse, cockroachdb, crdb-postgres, postgres, postgresql, pgx, redshift, cassandra, cockroach, mysql
Obtained by running:
migrate -help
Go Version
e.g. go version go1.11 linux/amd64
Obtained by running:
go version
1.21
Stacktrace
Please provide if available
Additional context
Add any other context about the problem here.
I followed this issue and then when it came to the command
$ migrate -path migrations/ -database $CHESS_DB_DSN force <VERSION>
I get the error:error: can't read limit argument N
so now I am stuck... also a side note: If I am running this command as version 1 for the first time then what previous version am I supposed to revert to? version 0?
The text was updated successfully, but these errors were encountered: