Skip to main content
Added SQL query example of getting the requested collection data.
Source Link
speshak
  • 537
  • 1
  • 6
  • 13

You might be able to exploit the fact that a LR catalog is actually a SQLite database. I've written ruby scripts in the past to generate statistics on my photos. The sort of data you're after probably isn't much more difficult to produce.

Mac OS ships with the sqlite command line tools. If command line interfaces aren't your thing, there are several different SQLite GUIs in the Mac App Store.

See this for a (older, but still valid) quick intro to pulling the data.

Edit

I cracked open my LR CC catalog and mocked up a quick test of my theory. I ended up with the following query:

SELECT lf.idx_filename
FROM AgLibraryCollection AS c,
  AgLibraryCollectionImage AS ci,
  Adobe_images AS i,
  AgLibraryFile AS lf

WHERE c.id_local = ci.collection
  AND i.id_local = ci.image
  AND lf.id_local = i.rootFile
  AND c.name = 'Collection Name'

The easiest way to execute this is to install SQLite Free - Datum from the Mac App store, open your Lightroom catalog (make sure LR is closed) and stick the query in the SQL tab. A more complex (but easier to repeat) method would be to stick the query in a text file, and run the following in Terminal:

sqlite3 /path/to/lightroom_catalog.lrcat < query.txt

You might be able to exploit the fact that a LR catalog is actually a SQLite database. I've written ruby scripts in the past to generate statistics on my photos. The sort of data you're after probably isn't much more difficult to produce.

Mac OS ships with the sqlite command line tools. If command line interfaces aren't your thing, there are several different SQLite GUIs in the Mac App Store.

See this for a (older, but still valid) quick intro to pulling the data.

You might be able to exploit the fact that a LR catalog is actually a SQLite database. I've written ruby scripts in the past to generate statistics on my photos. The sort of data you're after probably isn't much more difficult to produce.

Mac OS ships with the sqlite command line tools. If command line interfaces aren't your thing, there are several different SQLite GUIs in the Mac App Store.

See this for a (older, but still valid) quick intro to pulling the data.

Edit

I cracked open my LR CC catalog and mocked up a quick test of my theory. I ended up with the following query:

SELECT lf.idx_filename
FROM AgLibraryCollection AS c,
  AgLibraryCollectionImage AS ci,
  Adobe_images AS i,
  AgLibraryFile AS lf

WHERE c.id_local = ci.collection
  AND i.id_local = ci.image
  AND lf.id_local = i.rootFile
  AND c.name = 'Collection Name'

The easiest way to execute this is to install SQLite Free - Datum from the Mac App store, open your Lightroom catalog (make sure LR is closed) and stick the query in the SQL tab. A more complex (but easier to repeat) method would be to stick the query in a text file, and run the following in Terminal:

sqlite3 /path/to/lightroom_catalog.lrcat < query.txt
Source Link
speshak
  • 537
  • 1
  • 6
  • 13

You might be able to exploit the fact that a LR catalog is actually a SQLite database. I've written ruby scripts in the past to generate statistics on my photos. The sort of data you're after probably isn't much more difficult to produce.

Mac OS ships with the sqlite command line tools. If command line interfaces aren't your thing, there are several different SQLite GUIs in the Mac App Store.

See this for a (older, but still valid) quick intro to pulling the data.