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 08-22-2020, 10:53 AM   #1
tranquilo2
Member
tranquilo2 began at the beginning.
 
Posts: 23
Karma: 10
Join Date: Jan 2015
Device: none
Incrementing a column for selected books

I need help, please, with an expression to use in the "Search for" and "Replace with" section of batch Search and Replace, to simply number a custom column starting with 1 and incrementing the value by 1 for each book in the selection.

Thank You.
tranquilo2 is offline   Reply With Quote
Old 08-22-2020, 11:35 AM   #2
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,443
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Moderator Notice
Moved post to its own thread
chaley is offline   Reply With Quote
Advert
Old 08-23-2020, 02:27 AM   #3
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
If you are talking about a series, the Manage Series plugin can do this. That can work on the built-in series, or a custom series column.

Otherwise, it probably needs a plugin. It probably wouldn't be that hard to adapt the Manage Series plugin to do this.

And for curiosity, why do you want to do this? What are you trying to achieve? Maybe we can suggest an alternative way of doing it.
davidfor is offline   Reply With Quote
Old 08-23-2020, 10:45 AM   #4
tranquilo2
Member
tranquilo2 began at the beginning.
 
Posts: 23
Karma: 10
Join Date: Jan 2015
Device: none
Thank you for the response. No, it's not about series. I'm just trying to produce different lists (later published as epub) of books of the type "Top 100 books about this", "Top 100 books about that", etc. In order to do this I need a custom column in the library that I can fill with a number 1 to nnnn quickly, but sorted as displayed in the library. I can achieve this with the plugin Import List, but it is painful slow, so I thought there was a simple way with some function of the type "n+1".

If you look at the library you see a read-only fixed column on the left with a 1 to nnn number. I need to export *that* number somehow.

Last edited by tranquilo2; 08-23-2020 at 10:48 AM.
tranquilo2 is offline   Reply With Quote
Old 08-23-2020, 10:55 AM   #5
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Just because it IS called a Series Custom Column, does not stop you from using it as a 'weighted List" Column. You can title it anything you like

TheList [1]
...
TheList[99]
So use the Manage Series PI to (re)order your list (Drag) from what it contained
theducks is offline   Reply With Quote
Advert
Old 08-23-2020, 12:12 PM   #6
tranquilo2
Member
tranquilo2 began at the beginning.
 
Posts: 23
Karma: 10
Join Date: Jan 2015
Device: none
Thank you. Just tried the Manage Series PI and it works, but I have 6000+ book records and reordering them takes just as long, if not longer, as the Import List, with less flexibility.

Thank you all for your help.
tranquilo2 is offline   Reply With Quote
Old 08-24-2020, 12:49 AM   #7
davidfor
Grand Sorcerer
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 24,905
Karma: 47303824
Join Date: Jul 2011
Location: Sydney, Australia
Device: Kobo:Touch,Glo, AuraH2O, GloHD,AuraONE, ClaraHD, Libra H2O; tolinoepos
Quote:
Originally Posted by tranquilo2 View Post
If you look at the library you see a read-only fixed column on the left with a 1 to nnn number. I need to export *that* number somehow.
Do you mean the first column? That is just a line number in the list and changes as you sort the books. There is an id that is unique to each book in the library. That can be extracted with command line tools and used for updating the metadata from the command line.

Another possibility is the Reading List plugin. It can group sets of books together. The order in the lists are the order the books are added, but, it can be changed. The Import List plugin has an option to put the books into a Reading List. The Reading List plugin does allow a book to be in multiple lists. Using series or anything else would probably mean multiple custom columns for multiple lists.

But, whatever you do is going to take time. The problem is you need to find the books, get them in the appropriate order, and then add whatever metadata is needed to keep that list and order. Because of that, I think the Import List is probably the simplest way.
davidfor is offline   Reply With Quote
Old 08-24-2020, 11:48 AM   #8
tranquilo2
Member
tranquilo2 began at the beginning.
 
Posts: 23
Karma: 10
Join Date: Jan 2015
Device: none
Thank you davidfor, yes, I agree, as I mentioned before I already use the Import List, and it works, but it is very slow; since the order changes every few days the time it takes to update the metadata becomes an issue. I was just trying to find a faster alternative but I can live with Import List.
tranquilo2 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to copy a custom column's content of selected book scmaybee Calibre 6 08-16-2019 03:58 AM
Move selected data from series column to a new custom column fvdham Library Management 3 06-02-2017 03:49 PM
Selected a couple of Authors/Series but Calibre not showing the books selected lizzyong Library Management 3 04-16-2015 07:47 PM
Is there a way to have an incrementing playcount JohnMeloche Library Management 4 10-13-2014 10:45 AM
Version not incrementing rbruceporter Calibre 11 11-27-2010 04:39 PM


All times are GMT -4. The time now is 08:23 AM.


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