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-17-2020, 12:24 PM   #1
chittu
Junior Member
chittu began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jun 2012
Device: nook
calibredb add tags to existing entry

I want to add tags on the top of existing tags of the ebook entry in the library, I can't use set_metadata because it replaces the existing tags. I have to do this for hundreds of books, so it is not possible for me manually copy and paste old tags.

How can add tags instead of replacing (for an existing ebook in the library)?
How can I retrieve only tags? (show_metadata id pulls all the metadata but how to get just tags?)
chittu is offline   Reply With Quote
Old 08-17-2020, 11:24 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
calibredb list --field=tags
kovidgoyal is offline   Reply With Quote
Advert
Old 08-20-2020, 12:23 PM   #3
chittu
Junior Member
chittu began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jun 2012
Device: nook
Quote:
Originally Posted by kovidgoyal View Post
calibredb list --field=tags
thanks but it pulls all the tags from the entire library, but I want to get the tags from a single entry like id 334, something like

$ calibredb --with-library "calibre_library" list --field=tags id 334
chittu is offline   Reply With Quote
Old 08-20-2020, 12:47 PM   #4
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,048
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by chittu View Post
thanks but it pulls all the tags from the entire library, but I want to get the tags from a single entry like id 334, something like

$ calibredb --with-library "calibre_library" list --field=tags id 334
In another section only the number of the ID is used: 334
you might try that. (the documentation is always playing catch up)
theducks is offline   Reply With Quote
Old 08-20-2020, 01:37 PM   #5
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
--search id:334
kovidgoyal is offline   Reply With Quote
Advert
Old 08-21-2020, 09:58 AM   #6
chittu
Junior Member
chittu began at the beginning.
 
Posts: 8
Karma: 10
Join Date: Jun 2012
Device: nook
Quote:
Originally Posted by kovidgoyal View Post
--search id:334
that works, thanks (this is missing in the documentation!)

Similarly, can you add (not replace) tags on the top of existing tags like below?

Code:
calibredb --with-library "ebook_calibre_library" add -T custom_tag --search id:3972
chittu is offline   Reply With Quote
Old 08-21-2020, 10:40 AM   #7
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
No, its not missing in the documentation: https://manual.calibre-ebook.com/gen...db-list-search

And sure you can read th documentation for set_metadata and combine it with list to get the existing tags, then add the tag to the list and call set_metadata
kovidgoyal is offline   Reply With Quote
Reply

Tags
calibredb, calibredb calibre-server, calibredb metadata import


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Parsing tags from a bibliographic entry and/or getting tags from Library of Congress kirk8677 Library Management 2 05-27-2020 06:48 PM
Update an existing Calibre entry with a new file DMcCunney Library Management 8 08-20-2016 06:54 PM
New NRC Handelsblad recipe with all formats downloaded in single calibredb entry smmadge Recipes 0 10-17-2012 03:26 AM
calibredb add -- how to add additional metadata? TuxGirl Calibre 16 12-29-2011 01:01 AM
[?] Add downloaded tags not overwrite existing? random43743 Calibre 7 01-11-2011 12:34 AM


All times are GMT -4. The time now is 01:58 PM.


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