![]() |
#16 | |
Connoisseur
![]() Posts: 58
Karma: 12
Join Date: Jan 2009
Device: none
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#17 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,414
Karma: 27757236
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
You can make part of a regular expression optional by appending a question mark to it
|
![]() |
![]() |
Advert | |
|
![]() |
#18 |
Connoisseur
![]() Posts: 58
Karma: 12
Join Date: Jan 2009
Device: none
|
OK, thanks, but when I make a part optional, when is it used? Is it used when there is more data left after the other parts have been filled?
I try "(?P<author>.+) - (?P<series>.+)? - (?P<title>[^_]+)" but the series part is not bypassed when there are fewer then two dashes in the name. Consequently, the title becomes "Al Sarrantonio - Pumpkin Head", instead of what I want it to be. Last edited by darkmonk; 01-18-2009 at 12:51 AM. |
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
K3 Here, Have any questions? | Anarel | Amazon Kindle | 15 | 08-26-2010 08:34 PM |
PRS-900 Two Questions | luqmaninbmore | Sony Reader | 21 | 02-21-2010 02:25 PM |
could somebody help me with my questions? | yingwu | Introduce Yourself | 1 | 05-27-2009 05:34 PM |
2 questions | AJ Starr | Which one should I buy? | 6 | 07-03-2008 12:37 PM |
Few questions about the V2 | AndrewLB | HanLin eBook | 2 | 07-10-2006 09:33 AM |