Register Guidelines E-Books Search Today's Posts Mark Forums Read

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

Notices

Reply
 
Thread Tools Search this Thread
Old 11-28-2020, 02:05 AM   #1
Jobasha
Junior Member
Jobasha began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Nov 2020
Device: Samsung Note 9, Calibre Companion, Moon+ Reader
How can I populate a user column with the second author in author list?

Hi!

I have a bunch of books where the second author (and any subsequent authors) represent the translator of the book. What I want to do is to automatically populate a user field called translator (which is of the same type as author) with all the authors except the first one.

I thought I could do this with 'search and replace' and regex, but it seems the regex works on each author independently

Any help would be appreciated!
Jobasha is offline   Reply With Quote
Old 11-28-2020, 08:00 AM   #2
capink
Addict
capink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipedia
 
Posts: 348
Karma: 47240
Join Date: Aug 2015
Device: Kindle
Try using this template:

Code:
{authors:sublist(1,0, & )}

Last edited by capink; 11-28-2020 at 08:02 AM. Reason: template chaged to include all subsequent authors
capink is offline   Reply With Quote
Advert
Old 11-28-2020, 03:28 PM   #3
Jobasha
Junior Member
Jobasha began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Nov 2020
Device: Samsung Note 9, Calibre Companion, Moon+ Reader
Thanks for the response!

So I believe I would use this when creating a custom column built from other columns.

The problem is I only want to apply it to a subset of items, and I think I can't change an item manually with this type column.
Jobasha is offline   Reply With Quote
Old 11-28-2020, 03:51 PM   #4
capink
Addict
capink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipediacapink knows more than wikipedia
 
Posts: 348
Karma: 47240
Join Date: Aug 2015
Device: Kindle
Calibre search and replace supports templates. So, choose the subset of books you want, and in calibre's search and replace:

Code:
search mode: regular expression
mode: replace field
search field: {template}
Template: {authors:sublist(1,0, & )}
search for: (.+)
replace with: \1
destination field: your destination field
capink is offline   Reply With Quote
Old 11-29-2020, 04:58 PM   #5
Jobasha
Junior Member
Jobasha began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Nov 2020
Device: Samsung Note 9, Calibre Companion, Moon+ Reader
Smile

Thanks Capink!

That works perfectly.
Jobasha is offline   Reply With Quote
Advert
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
2nd Author Column - Need help Chris_Snow Library Management 5 10-11-2014 06:04 PM
View All Author's Books in a Author list wolfskies Library Management 2 05-16-2013 10:57 PM
Displaying LN, FN in Author Column Lady Fitzgerald Library Management 53 07-26-2012 04:31 AM
Help. Author list gone quoddle Library Management 2 05-01-2012 04:19 AM
Changing the author column olgs Recipes 7 07-29-2011 12:50 PM


All times are GMT -4. The time now is 12:10 AM.


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