Skip to content

TimestamptzSqlite in SQLite schema breaks diesel migration (or gets overwritten) #4192

Answered by weiznich
badrihippo asked this question in Q&A
Discussion options

You must be logged in to vote

What's the recommended way to handle schema-driven migration generation? Should I just disable updating schema.rs and keep manually changing TIMESTAMPTZSQLITE into a supported format in the SQL? Or is there some other way to do it?

That's on of the cases where you are currently expected to manually change the generated SQL. We explicitly do not apply these migrations automatically for exactly this reason. As for updating the schema.rs file: The recommend way for this is to use a patch file as described in the corresponding guide (See the patch_file section there for details).

It took me a while to realise how to use TimestamptzSqlite. This is probably because I'm not familiar with Dies…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@badrihippo
Comment options

@andsmedeiros
Comment options

@weiznich
Comment options

Answer selected by badrihippo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants