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 05-20-2011, 02:54 AM   #1
ander111
Member
ander111 began at the beginning.
 
ander111's Avatar
 
Posts: 14
Karma: 20
Join Date: Dec 2010
Device: Sony Reader PRS-650
Exclude books w/certain tag by default?

Hi—Sorry if this has already been discussed here. I searched a bit but couldn't find anything specifically about it.

My library of e-books is divided into two major groups: those with the "sci-fi" tag (about 10% of the library), and everything else. Most of the time, I'd like to list everything else, and occasionally view the sci-fi titles separately.

I know how to list books with certain tags, so viewing the sci-fi books alone is no problem. But how can I set Calibre so, by default, it lists everything but the "sci-fi" -tagged books?

Calibre is so big on arcane features, doing something as basic as this must be quite simple—but you still have to know how to do it. :?)

Thanks, Ander
ander111 is offline   Reply With Quote
Old 05-20-2011, 03:22 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: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Use
Code:
not tag:"=sci-fi"
in the search box, without the apostrophes.

You might want to read the calibre manual section on searching and the calibre manual section on the tag browser.

Four hints:
1) If you click on a tag in the tag browser pane (usually on the left), that tag shows with a green + and you search for all books containing that tag. If you click the tag again, you see a red - and you search for books not containing that tag. Use this to see what the search values look like.
2) If you hold the shift or ctrl key while clicking in the tag browser, you can construct more complex multi-criteria searches.
3) You can save a search, then use it as a "restriction", creating a virtual library of the books that match the search.
4) You can set a restriction to apply at start up, which may be what you were asking for when you said "by default". See preferences -> behavior -> Restriction to apply ...
chaley is offline   Reply With Quote
Advert
Old 05-20-2011, 04:56 AM   #3
ander111
Member
ander111 began at the beginning.
 
ander111's Avatar
 
Posts: 14
Karma: 20
Join Date: Dec 2010
Device: Sony Reader PRS-650
chaley: Thanks for your help—that's brilliant.

I did read the manual's Search section, but it describes only finding ("searching for") terms, not excluding (filtering) them. (One does run into a bit of a semantics problem...)

Also, while I appreciate your explanation of the tag browser, I was lucky enough to know the tags I wanted to exclude. The books I've imported have such a crazy number of tags, my Tag Browser is an overwhelming, pointless cascade of detail. I suppose if one had the time and the OCD tendencies, one could hack through all of one's books and impose some kind of order. Perhaps in another life... E:?|

In case anyone else should want to exclude books by tag, I'll describe the actual procedure below. No need to make everyone reinvent the wheel, eh? Cheers, Ander

- - - - - -

How to:

• Filter out books containing certain tags

• Do it again whenever you wish with just a couple of clicks

• Set Calibre to do it automatically when it starts

For this example, we'll use the tags "sci-fi" and "science fiction". Substitute the actual tag(s) you want to exclude.

(Note: Calibre calls everything a "search"—even though in a case like this, where we're excluding stuff rather than looking for it, it would normally be called a "filter".)

1. In the Search box, type:

not tag:"sci-fi", not tag:"science fiction"

(Notice how each exclusion must be separated by a comma and space. If you're excluding just one tag, the comma isn't necessary.)

2. The list refreshes, excluding books with either of those tags.

3. In the Saved Searches box (to the right of the main Search box), type a name that you want to call this search, e.g.:

Exclude sci-fi books

4. To the right of the Saved Searches box, click the far-right "magnifying glass with plus sign" button—which, when you hover over it with your mouse pointer, says:

"Save the current search under the name shown in the box..."

5. In the Tag Browser at the left (the list that begins "Authors, Series, Formats..."), a new category appears called "Searches". If you click the category to expand it, you'll see your search has been added there. You can click your saved search at any time to toggle your exclusions on and off.

Now, to apply your search (filter) automatically when Calibre starts:

1. At the top of Calibre's window, click Preferences. The Preferences window appears.

2. In the "Interfaces" section, click Behavior. The Behavior window appears.

3. At the upper right, in the list that says "Restriction to apply when the current library is opened", select your saved search's title.

4. Click Apply, then click Close.

To search for other stuff, leaving your exclusions in effect: In the Search box, type a space after your saved search's text, then type the text you're looking for.

To cancel your search (that is, filter) and show all books again, delete your search's text from the Search box (or toggle it off in your Saved Searches, as described above).
ander111 is offline   Reply With Quote
Old 05-20-2011, 05:48 AM   #4
itimpi
Wizard
itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.itimpi ought to be getting tired of karma fortunes by now.
 
Posts: 4,552
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
Quote:
Originally Posted by ander111;1546047"
(Notice how each exclusion must be separated by a comma and space. If you're excluding just one tag, the comma isn't necessary.)
You can also use the keyword 'and' here which I prefer to use as it is more consistent with using 'not ' and 'or' as other keywords. Brackets can also be used for grouping terms in complex searches to get precedence order correct.
itimpi is offline   Reply With Quote
Old 05-20-2011, 06:38 AM   #5
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: 11,734
Karma: 6690881
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by ander111 View Post
Also, while I appreciate your explanation of the tag browser, I was lucky enough to know the tags I wanted to exclude. The books I've imported have such a crazy number of tags, my Tag Browser is an overwhelming, pointless cascade of detail. I suppose if one had the time and the OCD tendencies, one could hack through all of one's books and impose some kind of order. Perhaps in another life... E:?|
The point was to provide a way to build the queries so you could see how calibre does it.
Quote:
(Note: Calibre calls everything a "search"—even though in a case like this, where we're excluding stuff rather than looking for it, it would normally be called a "filter".)
One of those semantic differences. Search expressions can contain both positive and negative criteria, making the distinction between a search and a filter difficult. What kind of thing is "A and not (B or C)"? In any event, even positive criteria "filter" the list, showing only those items that match the criteria.
Quote:
(Notice how each exclusion must be separated by a comma and space. If you're excluding just one tag, the comma isn't necessary.)
The comma is never necessary, and in some situations can be an error. An example: 'tags:=xx,' will want to find a comma in the tag (which it will never find), while with 'tags:"=xx",' the comma is ignored.
Quote:
To cancel your search (that is, filter) and show all books again, delete your search's text from the Search box (or toggle it off in your Saved Searches, as described above).
Or push the reset search button next to the "Go!" button on the search toolbar.
chaley is offline   Reply With Quote
Advert
Old 05-20-2011, 11:56 AM   #6
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by itimpi View Post
You can also use the keyword 'and' here which I prefer to use as it is more consistent with using 'not ' and 'or' as other keywords.
I like to use "and" if I'm saving a complex search, but it's not required (and the comma isn't needed either). The default search logic "ands" each search element, unless otherwise specified, so I very seldom use it.

Quote:
Brackets can also be used for grouping terms in complex searches to get precedence order correct.
Brackets "[ ]" don't seem to work for me. Parentheses "( )" work and are what I use.

As to the "search" vs. "filter" terminology, I suppose you could say that with the highlighting option turned on, it "searches," but doesn't "filter," while with it turned off (the default) it does both.
Starson17 is offline   Reply With Quote
Old 01-13-2014, 03:15 PM   #7
arudolph
Junior Member
arudolph began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Jan 2014
Device: Kindle Touch
I was trying to do this very same thing and I found this post. Thank you! Thank you! Thank you! It works and it has taken my calibre experience to a whole new level
arudolph is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calibre-Server - exclude books (by tag?) edent Calibre 1 05-18-2011 11:31 AM
602 Is there a list of the default free books? J.C. PocketBook 0 03-02-2011 04:03 AM
Is it possible to exclude tags/titles in the default view? texasnightowl Calibre 17 08-18-2010 12:11 PM
Any way to tag certain books not to be shared on my content server? Timber Calibre 1 07-20-2010 04:54 PM
Books We Like - tag and review books Colin Dunstan Deals and Resources (No Self-Promotion or Affiliate Links) 0 04-18-2005 05:36 AM


All times are GMT -4. The time now is 04:31 PM.


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