in reply to •Re: Improved regexp sought
in thread Improved regexp sought
Point taken merlyn.
I have a file with multiple lines in. Each line consists of a variable number of variable-length fields separated by a + character. Each line is terminated by a ' character. Sometimes, a field might have a ' character in it - if so, the ' is preceeded by a question-mark. Here are some example lines:
I want to break each line up into its constituent fields. I can do it with brute force, but would prefer elegance.0010+2+O'Reilly' 023++++234+35+White+++17+' g?'day mate+++'
Thanks
Myomancer
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Improved regexp sought
by duff (Parson) on Oct 27, 2004 at 14:39 UTC | |
|
Re^3: Improved regexp sought
by diotalevi (Canon) on Oct 27, 2004 at 14:54 UTC | |
|
Re^3: Improved regexp sought
by Limbic~Region (Chancellor) on Oct 27, 2004 at 14:43 UTC |