You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 18, 2021. It is now read-only.
I'm learning aqueduct. After running dart pub run aqueduct db generate and dart pub run aqueduct db upgrade --connect postgres://mobile:mobile@localhost:5432/ccd, I get the the following output. What's wrong (and how can I debug this kind of error)?
-- Aqueduct CLI Version: 3.3.0+1
-- Aqueduct project version: 3.3.0+1
-- Updating to version 1 on new database...
PostgreSQL connecting, mobile@localhost:5432/ccd.
Initializating database...
CREATE TABLE _aqueduct_version_pgsql (versionNumber INT NOT NULL UNIQUE,dateOfUpgrade TIMESTAMP NOT NULL)
Applying migration version 1...
CREATE TABLE _authclient (id TEXT PRIMARY KEY,hashedSecret TEXT NULL,salt TEXT NULL,redirectURI TEXT NULL,allowedScope TEXT NULL)
CREATE TABLE _authtoken (id BIGSERIAL PRIMARY KEY,code TEXT NULL UNIQUE,accessToken TEXT NULL UNIQUE,refreshToken TEXT NULL UNIQUE,scope TEXT NULL,issueDate TIMESTAMP NOT NULL,expirationDate TIMESTAMP NOT NULL,type TEXT NULL)
CREATE INDEX _authtoken_code_idx ON _authtoken (code)
CREATE INDEX _authtoken_accessToken_idx ON _authtoken (accessToken)
CREATE INDEX _authtoken_refreshToken_idx ON _authtoken (refreshToken)
CREATE INDEX _authtoken_expirationDate_idx ON _authtoken (expirationDate)
CREATE INDEX _authtoken_type_idx ON _authtoken (type)
CREATE TABLE _Graduate (name TEXT NOT NULL,program TEXT NOT NULL,institution TEXT NOT NULL,clientCode TEXT NOT NULL UNIQUE,project TEXT NOT NULL,graduationDate TIMESTAMP NOT NULL,id BIGSERIAL PRIMARY KEY,username TEXT NOT NULL UNIQUE,hashedPassword TEXT NOT NULL,salt TEXT NOT NULL)
CREATE INDEX _Graduate_username_idx ON _Graduate (username)
CREATE TABLE _Event (id BIGSERIAL PRIMARY KEY,flyerUrl TEXT NOT NULL,name TEXT NOT NULL UNIQUE,beginDateTime TIMESTAMP NOT NULL,endDateTime TIMESTAMP NULL,address TEXT NOT NULL,discount TEXT NOT NULL,facebook TEXT NULL)
CREATE TABLE _Partner (id BIGSERIAL PRIMARY KEY,logoUrl TEXT NOT NULL,name TEXT NOT NULL UNIQUE,address TEXT NOT NULL,phone TEXT NULL,facebook TEXT NULL,instagram TEXT NULL,discount TEXT NOT NULL,segments null NOT NULL)
*** There was an issue. Reason: syntax error at or near "null". Table: null Column: null
I didn't realize it. In fact, this migration file is the second version. I had these models with different properties before and generated the migration file for these models, but when I changed the Graduate model to work with OAuth, I tried to generate the migration file again, but it didn't work, so I had to delete this migration file to be able to generate a new one.
I say this because in the first migration file I had no problems, and the only changes made were in the Graduate model...
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I'm learning aqueduct. After running
dart pub run aqueduct db generate
anddart pub run aqueduct db upgrade --connect postgres://mobile:mobile@localhost:5432/ccd
, I get the the following output. What's wrong (and how can I debug this kind of error)?PostgreSQL version
Migration file
Models
The text was updated successfully, but these errors were encountered: