-
Notifications
You must be signed in to change notification settings - Fork 14
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
fix(migrations): CockroachDB compatibility & separate permission tables #204
Conversation
Keyword::CurrentTimestamp
to stay compatible with CockroachDBKeyword::CurrentTimestamp
to stay compatible with CockroachDB
Keyword::CurrentTimestamp
to stay compatible with CockroachDB
I found some issues in the data model when testing, I will need to fix them and ask for review again. |
We get the following error when running the migrations in CockroachDB:
Here is the explanation of the why from ChatGPT: The error “unknown signature: current_timestamp() (returning )” during migration with Sea ORM when using CockroachDB is likely due to the way current_timestamp() is being interpreted. CockroachDB has specific functions and expected return types for date and time operations which can cause compatibility issues if not used correctly. In Sea ORM, you typically define default values for timestamp columns using functions like current_timestamp(). However, CockroachDB has distinct variants of current_timestamp() that return different types, such as timestamp or timestamptz (timestamp with time zone). If the function call is not recognized with the correct return type, it results in the mentioned error. |
create_time