View Single Post
Old 12-15-2013, 04:00 PM   #8
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Well then, it seems we're both right, because using :.1 from the example (this is my first time using a substring, and first thing I did was test out the OP's string) works.

Plus this, once I looked it up in response to your prompting: http://manual.calibre-ebook.com/temp...ced-formatting

Quote:
If you want only the first two letters of the data, use:

{author_sort:.2} - Only the first two letter of the author sort name

The calibre template language comes from python and for more details on the syntax of these advanced formatting operations, look at the Python documentation.
eschwartz is offline   Reply With Quote