Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 01-27-2013, 12:35 AM   #1
macnab69
Zealot
macnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toysmacnab69 shares his or her toys
 
Posts: 129
Karma: 5754
Join Date: Jan 2012
Location: South Africa
Device: Kindle 4
Bulk move 'The' and 'A' to end of Title

Because of the way I handled things before using calibre I have a large number of books whose Titles are 'The xxxxx xxxx' and "A xxxx xxxx'.

Is there a way of automating conversion to 'xxxxx xxx, The' and 'xxxx xxxx, A'.

I can use a regex in Search and Replace to remove 'The" and 'A', but there doesn't seem a way to add them to the end.

Without creating a new column with the modified values and hiding the original.
macnab69 is offline   Reply With Quote
Old 01-27-2013, 01:18 AM   #2
DoctorOhh
US Navy, Retired
DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.DoctorOhh ought to be getting tired of karma fortunes by now.
 
DoctorOhh's Avatar
 
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
Quote:
Originally Posted by macnab69 View Post
Because of the way I handled things before using calibre I have a large number of books whose Titles are 'The xxxxx xxxx' and "A xxxx xxxx'.

Is there a way of automating conversion to 'xxxxx xxx, The' and 'xxxx xxxx, A'.
Not exactly what you are asking, but you might find this acceptable. Go to Preferences - Tweaks and change the Control sorting of titles and series in the library display to title_series_sorting = 'library_order'.

Even though the titles will still show 'The xxxxx xxxx' and "A xxxx xxxx' they will sort as 'xxxxx xxxx, The' and "xxxx xxxx, A'.
DoctorOhh is offline   Reply With Quote
Old 01-28-2013, 06:49 AM   #3
Manichean
Wizard
Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.Manichean is the 'tall, dark, handsome stranger' all the fortune-tellers are referring to.
 
Manichean's Avatar
 
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
Using a regex for this should be possible. You just need to use named back references and write one expression to capture The and A, and the other to capture the rest of the title. Then it's trivial to reorder them in the replace expression
Manichean is offline   Reply With Quote
Old 01-28-2013, 09:26 AM   #4
Adoby
Handy Elephant
Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.Adoby ought to be getting tired of karma fortunes by now.
 
Adoby's Avatar
 
Posts: 1,736
Karma: 26785668
Join Date: Dec 2009
Location: Southern Sweden, far out in the quiet woods
Device: Thinkpad E595, Ubuntu Mate, Huawei Mediapad 5, Bouye Likebook Plus
Search for: A (.*)
And replace with: \1, A

Or

The (.*)
\1, The

But it is better to use the tweak described above. The title is what it is, you typically only wish to change the sort order.

Last edited by Adoby; 01-28-2013 at 09:31 AM.
Adoby is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Title bulk edit match - to remove series info from title Rob557 Library Management 30 12-09-2014 06:06 AM
Bulk title replacements mumdigau Recipes 0 07-22-2012 12:34 PM
Four Squares Appear at the End of the Title raczyk Recipes 7 03-17-2012 09:50 PM
Bulk Title Mod Option?? kksdragons Library Management 1 10-27-2011 10:42 PM
Reg ex to move 'by author' from title field maartencoertjens Library Management 3 10-20-2011 04:26 PM


All times are GMT -4. The time now is 09:41 PM.


MobileRead.com is a privately owned, operated and funded community.