Quote:
Originally Posted by theducks
It is all about identifying patterns you can latch onto as triggers.
Using your sample
Code:
Dead Silence (The Body Finder, #4)
first: series info is delineated by the ( and )
second: the series_index value is DIGITS after a , # (comma space hash)
so now we know where series starts and ends and where the number is
 We also see there are some special REGEX reserved characters that will need special treatment (I have split onto many lines to explain ONLY)
Dead Silence (The Body Finder, #4)
(.+) \( capture #1 the Title and eliminates the space (
(.+)\,\s\# capture #2 the series name and eliminates the comma space hash
(\d+)\) capture #3 grabs the series_index and eliminates the closing )
All together:
Code:
(.+) \((.+)\,\s\#(\d+)\)
A replace of: \1 (\2, #\3)
would put it all back together 
|
Thank you for the REGEX and for the explanation. And yes that made sense to me. I appreciate the help of everyone.
