문제

Since I have been preparing my Play! app for production and started backfilling the database, I have modified my models quite a bit. I am now up to 8.sql in my evolutions scripts and I was wondering if there was a way to consolidate these and start over at 1.sql.

Can I rewrite 1.sql to model my current schema and delete 2-8? Or will this cause Play to freak out?

It isn't a huge deal as I don't believe there is a limit on the number of evolutions scripts you can have, but it would be neater to have fewer. The reason I can't just delete my tables and start over is that I have data in there I would rather not delete.

I could probably back my data up and then reimport it except that I have spatial data (PostGIS) and I'm not sure if that would back up properly.

도움이 되었습니까?

해결책

I don't think it is a good idea since the evolution script stores some metadata in your database (table play_evolutions), especially, it computes a hash against the SQL source code.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top