View Single Post
Old 09-01-2010, 02:46 PM   #13
dmapr
Addict
dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.dmapr composes epic poetry in binary.
 
Posts: 257
Karma: 90958
Join Date: Sep 2009
Device: PRS-950, Kobo Aura HD
Quote:
Originally Posted by chaley View Post
It is in the USB base plugin, which the sony plugin inherits from.

I would prefer a tweak over duplicating the driver.
Understood.

Quote:
Originally Posted by chaley View Post
The series index for custom columns is in the link table.

Kovid made a fundamental choice made early in calibre's development, to use a denormalized view as the interface between the GUI and the DB. This choice makes a lot of sense when using a tabular interface vs a forms interface. A consequence is that there is a view column per display/sortable/searchable column. Naturally multiple fields like tags and authors are collapsed into a single comma-separated list.
I agree that the choice makes total sense for the tabular view, but it doesn't explain why the series_index is in the books table. The view still has to use the link table to get the series name, it would've been able to pick up the series from that table as well — without hampering the programmatically imposed restriction of one book being a member of one series only — just the way it does with user-defined columns. However at this point it's purely an academic discussion since as you pointed out the database schema isn't changing any time soon.

On the other hand, this does present an interesting problem to think about — obviously the comma-separated list of series doesn't make much sense…
dmapr is offline   Reply With Quote