Replace media files automatically

I have a lot of media files (jpeg) in my Omeka S installation. They have been migrated from an old website and are not of the best quality. I would like to replace them by new files, of better quality.

Old files and new have the same name but Omeka S renames files when added, so I don’t have access to the name of old files.

I wondering if there is an automatic way to replace all media files by new ones? I don’t believe so since the name is lost when importing into Omeka S.

There is no way through the UI.

Perhaps with Daniel KM’s CSVImport+ with the import option set to replace or update?

Unless it is important for the files to maintain the same name, you can just replace the old files with the new files and let Omeka rename them.

In our Omeka-S instance, we use an internal identifier mapped to dcterms:identifier as the primary ID of the record (as opposed to the Omeka internal ID).

So it would be pretty easy to construct a CSV file to import with filenames (actually, URLs) + the item’s internal identifier. And if you need to extract the omeka ID, I can show you how to do that if you can get access to the database to run a SQL query.