08-16-2011, 11:51 AM | #1 |
eBook Junkie
Posts: 1,526
Karma: 1464018
Join Date: May 2010
Location: USA
Device: Kindle Fire 2020, Kindle PW2
|
Add Books - Regex Help Please
Hi:
I have some books that are named like this Anthony, Piers - Xanth 28 - Currant Events This is the regex which I have now: (?P<author>[^_]+) - (?P<series>[^_]+) - (?P<title>.+) Can someone help me adjust it so that the index number (28 in this example) can be inputted into the index field instead of part of the series name? Nyn |
08-16-2011, 12:10 PM | #2 | |
Well trained by Cats
Posts: 29,778
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
Code:
^((?P<author>([^\_0-9]+)(?=\s*-\s*)(?!\s*-\s*[0-9.]+)|\b))(\s*-\s*)?((?P<series>[^0-9\-]+) ([-#] ?)?(?P<series_index>[0-9.]+)?\s*-\s*)?(?P<title>.+) |
|
Advert | |
|
08-16-2011, 01:30 PM | #3 |
eBook Junkie
Posts: 1,526
Karma: 1464018
Join Date: May 2010
Location: USA
Device: Kindle Fire 2020, Kindle PW2
|
It works perfectly.
|
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Add Book Regex to Custom field | adept22 | Library Management | 3 | 10-07-2014 07:33 PM |
Problem with "Add Books" regex | wygit | Library Management | 9 | 07-24-2011 12:24 PM |
understandng the sample add books regex | cybmole | Library Management | 11 | 03-02-2011 06:08 AM |
A little help adding books and using regex. | Dragonator | Calibre | 7 | 12-17-2010 06:57 PM |
Add book regex no longer works | magphil | Calibre | 3 | 03-24-2010 03:40 PM |