Page 1 of 1
DVD Pedia Feature Request
Posted: Mon Aug 02, 2010 9:08 pm
by DriverJC
Currently I am using DVD Pedia to cataglog the DVD's and TV Shows I convert for my AppleTV (currently 1900 entries and growing daily). I use this program to gather the information for the MP4 tags that I add to the files. At present the Encoding, Tagging, and Syncing to the Appropriate drives is handled Automatically (via Bash Scripts, and HandbrakeCLI for encoding, SublerCLI and AtomicParsley for tagging, and rsync for the syncing to various places), with the exception of me having to manually export the database to a CSV text file when information is added, as well as adding the Picture file that is in DVDPedia to the MP4 Tags.
It would save me time if I could find a way to export the database to a CSV file from the command line, and if that file could contain the path to the picture file stored in the database.
Thank you,
Joel Driver
Re: DVD Pedia Feature Request
Posted: Mon Aug 02, 2010 10:46 pm
by sjk
I don't know enough to fill in the details of your request, but in general you can use the sqlite3 command to directly access the ~/Library/Application Support/DVDpedia/Database.pediadata db file.
Re: DVD Pedia Feature Request
Posted: Tue Aug 03, 2010 8:01 am
by Conor
With such an extensive knowledge of programming, SJK is right the SQL access would be ideal for pulling out information. You can open access to the database with:
Code: Select all
sqlite3 ~/Library/Application\ Support/DVDpedia/Database.pediadata
With the database open run SQL commands to access data. "Zentry" would be the table that contain all the DVDs. The attributes names can easily be guessed at except that they all have a prefixed "Z" (although running ".schema" in SQLite will show you all the columns). The attribute zUID is a unique and the cover file inside the covers folder are named with after it. Use it to construct the path "~/Library/Application\ Support/DVDpedia/Covers/uid.jpg" to retrieve the covers.
If your script is already rigged for CSV and you don't want to deal with SQL then the following command will create an automatic CSV export:
Code: Select all
sqlite3 ~/Library/Application\ Support/DVDpedia/Database.pediadata
.mode csv
.output /users/me/Desktop/fileExported.csv
select * from zentry;