Skip to content

How to create Schema , run migrations #3136

Answered by wakaztahir
wakaztahir asked this question in Q&A
Discussion options

You must be logged in to vote

Ok I got it , sorry for the question
When the database version is 0 which should be by default , I should run Schema.create and set the database version to current schema version
and if database version is less than current schema version , I should migrate to current schema version

Saw the code here https://github.com/JakeWharton/dodo/blob/e64a6d12afcadba674a726cce37a1dd20414bf06/src/main/kotlin/com/jakewharton/dodo/db.kt#L27

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by wakaztahir
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant