[OSM-dev] 0.6 database table creation script for mysql?
brett at bretth.com
Tue Dec 9 22:25:07 GMT 2008
Maarten Deen wrote:
> Shaun McDonald wrote:
>> Maarten Deen wrote:
>>> Shaun McDonald wrote:
>>>> For MySQL, you can setup rails api06 branch, and run rake db:migrate.
>>> And to comment on rails_port_branches/api06/db/migrate/001_create_osm_db.rb in
>>> svn: I thought the tags on nodes were put in a separate table? At least that's
>>> what I I understand from the 0.6 wiki page.
>>> But the ruby script still makes a node table with a tags column and there is no
>> The migrations run through the full history of how the database used to
>> be structured.
> Ah, that was not clear to me. In general, why would you bother someone who just
> wants the latest database with the full history?
If you're using a rails installation, then it makes no difference how
the db gets created, it's always a simple rake db:migrate away. You
never have to re-create your database from scratch. And devs don't have
to maintain "from scratch" db schemas.
Of course, expecting people to install rails is another issue. But all
it takes is somebody to volunteer to keep an up-to-date schema script
somewhere. Nobody (aside from me ... read below) has done so up to this
>> I have uploaded the current structure to:
>> There are more foreign key constraints due to be added before 0.6 is
> Thanks, much appreciated.
> And IMHO it is not very considerate to expect people who just want to have the
> database to have them install rails and then get the output of one mangy little
Perhaps. We just need a volunteer to maintain the script :-)
> For all I'm worth, the latest database structure should be available for
> download as an easy create script. Just include it in Osmosis or so. I mean: you
> only have to include the script that osmosis works with (currently 0.5 and 0.6),
> it's not like there are a dozen versions to consider.
The osmosis download page does link to a schema script. Currently it's
the 0.5 version because 0.6 is still in a state of flux and I have
enough trouble keeping the 0.5 version up to date.
I don't like to include the script in osmosis itself because osmosis
doesn't control the mysql schema, I'm just a consumer of it like
But if somebody volunteers to keep an up to date schema script in the
osmosis svn I'm happy for them to do so.
More information about the dev