Thread: calibredb list
View Single Post
Old 10-12-2011, 06:26 AM   #1
iomari
Zealot
iomari doesn't litteriomari doesn't litter
 
Posts: 146
Karma: 100
Join Date: Aug 2003
Location: Nigeria
Device: galaxy tab
calibredb list

when I run the cli command:

calibredb list --help

Part of the output is:

-f FIELDS, --fields=FIELDS
The fields to display when listing books in the
database. Should be a comma separated list of fields.
Available fields: *date_entered,*formats,*myformats,*s
ep_tots,*supercat,*timestamp,*totsize,author_sort, auth
ors,comments,cover,formats,identifiers,isbn,last_m odif
ied,pubdate,publisher,rating,series,series_index,s ize,
tags,timestamp,title,uuid
Default: title,authors. The special field "all" can be
used to select all fields. Only has effect in the text
output format.


However, when I run the command:

calibredb list --separator="," --fields=supercat

It returns with the help screen and the last line is:

Invalid fields. Available fields: *date_entered,*formats,*myformats,*sep_tots,*super cat,*timestamp,*totsize,author_sort,authors,commen ts,cover,formats,identifiers,isbn,last_modified,pu bdate,publisher,rating,series,series_index,size,ta gs,timestamp,title,uuid

However this clearly shows that "supercat" is a field.

Problem 2:

when I run:

calibredb list --separator="," --fields=formats

I get this list: (just a snippet)

1344,[/home/iomari/calibre_library/iomari/Tony Gaddis/Starting Out With Python (1344)/Starting Out With Python - Tony Gaddis.pdf] ,
1345,[/home/iomari/calibre_library/iomari/Steven Bird/Natural Language Processing With Python (1345)/Natural Language Processing With Python - Steven ,
,Bird.pdf]


This is not what I expected from "formats:.
I expected to see just the formats like "EPUB, PDF..."

The reason I'm going through this exercise is because I need to get a list of the formats used in my database. Like you get under "Formats" int the GUI. So this is my first step so I can import this output to my script. Unless someone knows a simpler way to get a list of all the formats used as a list.

Last edited by iomari; 10-12-2011 at 06:31 AM.
iomari is offline   Reply With Quote