04-09-2011, 10:48 PM | #1 |
Member
Posts: 21
Karma: 10
Join Date: Jan 2011
Device: Kindle
|
Adding Books
Hi All
I am adding some books and the titles have all the details and have the same format. I have been playing with the regex stuff, but can seem to get more than a couple of the details at a time. Titles look like this: 002 - Foundation Series - [The First Trilogy] - Second Foundation (by Isaac Asimov).epub what is the regex to break this all apart to get the following results: Title: Second Foundation Authors: Isaac Asimov Series: Foundation Series - The First Trilogy Series Index: 002 Thanks in Advance CZ |
04-10-2011, 02:17 AM | #2 |
Wizard
Posts: 3,130
Karma: 91256
Join Date: Feb 2008
Location: Germany
Device: Cybook Gen3
|
What expressions did you try and what results did you get using them?
|
Advert | |
|
04-11-2011, 11:28 AM | #3 | |
Wizard
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
|
Quote:
Code:
(?P<series_index>[0-9]+) -?\s*(?P<series>[^_0-9]*)\s*-\s*(?P<title>[^_].+) ?\(by (?P<author>[^_].+)\) ? |
|
04-15-2011, 12:51 AM | #4 |
Member
Posts: 21
Karma: 10
Join Date: Jan 2011
Device: Kindle
|
Thanks, had the update email set to weekly, so I didn't get an update till today.
@Manichean I didn't keep what I was doing, as it wasn't working. Suspect it was an absence of a \s* or two, as they don't look familiar. @ Starson17 - thats pretty much it, i can tweak it from there. |
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Saving after adding books | KKneko7 | Calibre | 4 | 01-17-2011 09:55 PM |
Adding properties to books | IzzyMad | Workshop | 3 | 10-15-2010 11:05 AM |
delete old books after adding | iconeo | Calibre | 4 | 05-21-2010 01:03 AM |
Help with adding books please | stustaff | Calibre | 12 | 10-27-2009 02:30 PM |
Problems adding books in 0.6.5 | lalawe | Calibre | 8 | 08-11-2009 12:46 PM |