play-slick icon indicating copy to clipboard operation
play-slick copied to clipboard

Evolutions file not created when 1.sql exists

Open hilton opened this issue 12 years ago • 1 comments

play-slick only creates an evolutions file for you if you don't have one yet. That's what you want when you first create your model, but doesn't allow you to use this feature when you later change your model and need to create a 2.sql, perhaps with a new table.

Suggestion: instead of generating 1.sql if it isn't there, generate create.sql and drop.sql unless a configuration parameter is set to false. Then you can write your 2.sql based on the diff between 1.sql and create.sql.

I can also imagine situations on a project where you want to run the whole create or drop script on a test database.

hilton avatar Jul 04 '13 16:07 hilton

I think tid is great idea :)

freekh avatar Jul 04 '13 18:07 freekh