View Single Post
Old 05-15-2012, 03:26 AM   #298
Junior Member
Euclase began at the beginning.
Posts: 2
Karma: 10
Join Date: Mar 2012
Device: Kindle Touch
Originally Posted by Gary_M_Mugford View Post

Check out the ifempty function. My own Kindle pegboard is a bit convoluted since it uses custom columns to reduce the series title to six characters or less (using initials where necessary). But the principal can probably help you.

[{#readrank:ifempty(9)}{#genre:ifempty(SF)}] {#stripped_series:lookup(.\s,#initials,.,#shortene d,series)}{series_index:|-|-}{title}

Note the use of ifempty in a couple of the columns. What I would do with yours is to try series:ifempty(--) in place of series:. That would create a -- at the start of any title without a series entry and those SHOULD sort to the front in title sort on the Kindle. Haven't tried it, but it 'should' work.

Hi Gary,

My sincere apologies for not replying sooner with feedback to your advice. Life became a snowglobe that someone turned over, and things have only now settled, permitting me to tinker in Calibre again. The good news is the ifempty function works! My plugboard now looks like this (I repeated the plugboard for both my .mobi formats and my .azw formats to successfully cover all my bases):

{series:ifempty(--)}{series_index:0>2s|[|] - }{title}

The only (minor) bad news is, as my template stands now, it works 98% of the time. Standalone titles that start with a "The" article, e.g. The Call of The Wild, ended up mixed in with the series. Perhaps I'll uncover a solution for that in time (besides having Title, The in the original metadata field). Thank you very much for your help!

Last edited by Euclase; 05-15-2012 at 03:48 AM.
Euclase is offline   Reply With Quote