Skip to content
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

Implement migrations #4

Open
tejainece opened this issue Jul 26, 2017 · 13 comments
Open

Implement migrations #4

tejainece opened this issue Jul 26, 2017 · 13 comments

Comments

@tejainece
Copy link
Member

Implement migrations

@tejainece
Copy link
Member Author

Started an experimental implementation here: 29f27d9

@tejainece
Copy link
Member Author

The plan is to create a snapshot (an xml file) for each changes. Store these snapshot files.

Diff the snapshot files to migrate up or down.

@tejainece
Copy link
Member Author

Blocked by #19

@hjJunior
Copy link

hjJunior commented Apr 6, 2019

Hey, what do think about create a __migrations__ table on schema to manage the migrations executed instead xml files?

This approach is used in many frameworks, if u agree I think that I can help on it!

@tejainece
Copy link
Member Author

That definitely sounds nice!

@tejainece
Copy link
Member Author

@hjJunior Are you still planning to work on this issue?

@hjJunior
Copy link

hjJunior commented Jul 2, 2019

I was :/ but I faced a problem that go against the way is used generator on project

@tejainece
Copy link
Member Author

Can you please explain more?

@hjJunior
Copy link

hjJunior commented Jul 3, 2019

oc! well, I was planing to create a migration when the flutter pub run build_runner build, but I'll need to check if changed and/or what changed on database schema, and late it, if required create a new file/a new migration version with the diffs
I'd like to follow something like the room migrations but a little more automatic

@flycash
Copy link

flycash commented Sep 26, 2019

@hjJunior Do you made any progress? Or are you still working on this?

@hjJunior
Copy link

Sorry guys, when I was planning to start, I just figure out another one, that already do this, take a look on Floor

@devjeff
Copy link

devjeff commented Feb 27, 2020

The Floor approach looks nice, but it is still SQFlite specific. A migration implementation directly in the jarguar orm package would provide a possibility to handle DB migrations independently of the used database.

@SebastienSCochet
Copy link

Is there any update about this ? Any example of a simple implementation ? Thank you for your hard work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants