Commit graph

5 commits

Author SHA1 Message Date
bsag
02496f2d44 Updated to svn tags/tracks-1.6 2008-06-03 19:40:22 +01:00
lukemelia
06f14dd3b9 And here's the copy step.
git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@501 a4c988fc-2ded-0310-b66e-134b36920a42
2007-03-30 04:36:52 +00:00
lukemelia
c34d9faa38 Arg. Branching never seems to "just work". Going to delete and recopy. Here's the delete step.
git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@500 a4c988fc-2ded-0310-b66e-134b36920a42
2007-03-30 04:36:14 +00:00
bsag
cf0d56e10b Changed all the created_at and updated_at fields back to a null default to fix #301. It seems that the problem with datetime fields and Postgresql was a Rails bug that was fixed in 1.1, so it should be OK now.
Unfortunately, I couldn't seem to create a migration to revert the fields, so I had to alter the older migration files. This means that if you're using the trunk you need to export your data, delete the database, create it again, run rake db:migrate and then reimport your data. Make sure you backup the whole database first, just in case!



git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@261 a4c988fc-2ded-0310-b66e-134b36920a42
2006-06-10 13:57:59 +00:00
bsag
6dc32aa83b Updated the migration files so that any updates to rows are done via ruby rather than raw SQL. With any luck at all, this might fix the various problems people encounter when trying to use rake migrate on different databases. At any rate, it should be a lot more portable between databases.
Also added some ruby code to the fixture files so that boolean columns will be set correctly depending on database adapter, and also the created_at and other date or datetime fields are set dynamically.

Finally, I also changed the names of the old migration files to match the new naming convention (001_filename.rb, 002_filename.rb etc.)

With the new rake syntax, you can run:

rake db:migrate

to create the tables (for MySQL create the db first, but with sqlite/sqlite3 you just have to list the name in database.yml, but you don't need to create the db itself). Then,

rake db:fixtures:load

if you want some example contents.

I'm HOPING that this fixes #261, #268 and even #205 which I closed because I gave up. I've tested rake db:migrate and rake db:fixtures:load by creating new mysql and sqlite3 databases, and that works fine on my system.



git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@233 a4c988fc-2ded-0310-b66e-134b36920a42
2006-05-02 21:47:30 +00:00
Renamed from tracks/db/migrate/5_add_project_description.rb (Browse further)