updating mysql database

If I manually 'update' (official SQL update command) a bunch of titles or other fields via a CSV file in the database it looks like I need to update the omeka_items table. Do I need to update the omeka_files table as well? Or any other tables? Thanks for any insight.

If you're only updating the dublin core metadata for an item, then the items table is what you will need to update. The files table contains dublin core metadata for the files that are attached to the items, but it doesn't sound like you want to edit that as well. Hope that helps.

Does that apply to importing a csv file to make new records on the items table? Where else might I be breaking the item_id as foreign key? (Say, vs doing some data cleanup in the admin area).

Any more hints on when the new version will be out with the CSV importer? Otherwise, I'm really enjoying working with Omeka and think it's turning into a great product.

Using a CSV to make new records should be fine because the items table doesn't depend on any other tables via foreign key relationships (usually it's the other way around). There are, however, a couple of fields that are split into different tables. For example, the 'entities_relations' table stores a list of the users who have added or modified specific items along with timestamps. Omeka may work fine if you don't add appropriate data to this table, but i'm not totally sure. Depending on what you're doing, you could always try it and revert to a backup if it doesn't seem to work out.

Also, with regards to the upcoming new version of Omeka, we're thinking maybe a month or so for an alpha release that people will be able to play with, but the CSV importer will most likely be available as a plugin and we haven't really decided on a release schedule for that.

Thanks for the support, always good to hear from happy users!

We've taken a roundabout approach. The site we're working on has over 38,000 photos (will launch in August sometime), and we have all the Dublin Core metadata in spreadsheets. Although I've tested the following procedure, I still wanted to ask about the omeka_items table before I proceeded to update the table.

Our procedure has been:

  • Batch upload all the images into appropriate collections.
  • Clean up the spreadsheets to match Dublin Core.
  • Save spreadsheets as a CSV files (: delimited though).
  • And then run some scripts to convert the CSV files into MySQL statements.
  • So the MySQL statements look like this:

update omeka_items
set title = "fooBar"
set publisher = "news org"
where id = " ";

I've tested it out in small batches on my home machine and it seems to work well. The only time consuming part is matching the ID in the MySQL statement with the item's ID in the table, but it's not too bad. We just have to be careful because we're working with so many files.

After this is completed, we'll modify an existing theme and launch the site. Phase II will involve additional theme work. Specifically, because the site is going to be so big we'll need to work on navigation. Some collections will have 50 files. Others will have over a 1,000. We also want to work on adding advanced search on the public site. I don't really have much experience with PHP, but I want to get better at it and wouldn't mind working on that in a few months, if no one else does it. :)

It should be a nice site. We're very thankful to you all for Omeka. It's a wonderful program.

Sounds like you've got the process worked out pretty well. Feel free to let us know how it goes, and whether or not you run into any issues.