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-19-2012, 05:40 PM   #1
GeekyGal
Enthusiast
GeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavens
 
Posts: 40
Karma: 13888
Join Date: Sep 2010
Device: Kindle FireHD, Kindle3G, iPad, MacBook, iRex Illiad (ret)
Question Reg Ex Syntax to Exclude Genres - I'm Missing Something Obvious

Dear folks,

I KNOW that I'm missing something which should be obvious. I have tags which I want to exclude from genres in generating a .MOBI catalog. For example, tag

02 Fiction

has some uses, but pretty much wastes catalog space; I have more descriptive sub-categories. I no longer use a + tag for Already Read, but didn't think that would matter. I do want to include 02 Fiction.Mystery, 02 Fiction.F&SF, 02 Fiction.F&SF.Alternate History, etc.

I thought I read the default tooltip correctly to generate the catalog exclusion as either

\[02 Fiction]|\+


or

\[.02 Fiction\]|\+

to exclude the genre, but neither works. Yes, I have read the fine manual, but am just not seeing what I'm doing wrong. I'd like to exclude several tags once I figure this out. Is there a limit on the number of those? How would I write this?

THANK YOU, esteemed wizards.
GeekyGal is offline   Reply With Quote
Old 08-19-2012, 07:25 PM   #2
tilia
Evangelist
tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.tilia ought to be getting tired of karma fortunes by now.
 
tilia's Avatar
 
Posts: 432
Karma: 1720909
Join Date: Mar 2011
Device: Voyage, K3
Code:
02 Fiction
will exclude this tag. To exclude more tags use | to separate them:

Code:
02 Fiction.Mystery|02 Fiction.F&SF
If you want to exclude all tags starting with 02 Fiction use

Code:
^02 Fiction
The ^ means starts with.

[ has a special meaning in reg-ex, and a \ in front means that it should be read as a normal character. So if your tag was [02 Fiction] your reg-ex would be \[02 Fiction\]
tilia is offline   Reply With Quote
Advert
Old 08-19-2012, 09:28 PM   #3
GeekyGal
Enthusiast
GeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavensGeekyGal is a rising star in the heavens
 
Posts: 40
Karma: 13888
Join Date: Sep 2010
Device: Kindle FireHD, Kindle3G, iPad, MacBook, iRex Illiad (ret)
Red face

Thank you. Thank you. I knew I was overcomplicating this. Just excluding 02 Fiction also did exclude the subgenres which started with 02 Fiction.Whatever. I just renamed the first tag and left the rest alone. This accomplished exactly what I wanted.

I'm sorry to have had to have asked. As I said, the Reg Ex Help was clear, and I did read it, but for some reason I just wasn't getting it.

I really appreciate the help.
GeekyGal is offline   Reply With Quote
Old 08-19-2012, 10:35 PM   #4
lrui
Enthusiast
lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.lrui ought to be getting tired of karma fortunes by now.
 
lrui's Avatar
 
Posts: 49
Karma: 475062
Join Date: Aug 2012
Device: nook simple touch
Quote:
Originally Posted by GeekyGal View Post
Dear folks,

I KNOW that I'm missing something which should be obvious. I have tags which I want to exclude from genres in generating a .MOBI catalog. For example, tag

02 Fiction

has some uses, but pretty much wastes catalog space; I have more descriptive sub-categories. I no longer use a + tag for Already Read, but didn't think that would matter. I do want to include 02 Fiction.Mystery, 02 Fiction.F&SF, 02 Fiction.F&SF.Alternate History, etc.

I thought I read the default tooltip correctly to generate the catalog exclusion as either

\[02 Fiction]|\+


or

\[.02 Fiction\]|\+

to exclude the genre, but neither works. Yes, I have read the fine manual, but am just not seeing what I'm doing wrong. I'd like to exclude several tags once I figure this out. Is there a limit on the number of those? How would I write this?

THANK YOU, esteemed wizards.
Code:
02\sFiction\..*
it could match all the contents with string 02 Fiction.

all of this
Code:
include 02 Fiction.Mystery, 02 Fiction.F&SF, 02 Fiction.F&SF.Alternate History
hope it'll be helpful to you.

Last edited by lrui; 08-19-2012 at 11:51 PM.
lrui is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Reg-ex help...? ElMiko Sigil 11 12-06-2011 12:41 AM
Reg expression for importing Debby Library Management 2 02-17-2011 11:20 AM
DRM prob obvious question BBel Calibre 1 06-06-2010 11:47 PM


All times are GMT -4. The time now is 01:56 AM.


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