[ List Archives Home ] [ Thread index for 2008 ]
[ Date index for 2008 ]
[ Author index for 2008 ]
[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
Bob,
I think your interpretation of "..[^(je)]." is correct. Maybe this is
one of those things that works in some other implementation of regular
expressions, but not in Create Lists. I agree that John Boggs'
suggestion using two AND'ed statements should work perfectly.
Negative matching -- which can get much hairier than this example --
would be so much easier if we had available a "does not match" condition
or, for that matter, a simple Boolean NOT operator.
Richard V. Jackson
Head of Copy Cataloging / Database Manager
Huntington Library, Art Collections, and Botanical Gardens
1151 Oxford Road, San Marino, CA 91108
rjackson at huntington dot org / 626-405-2100 x2384
-----Original Message-----
From: innopac-bounces at innopacusers dot org
[
mailto:innopac-bounces at innopacusers dot org] On Behalf Of Bob Duncan
Sent: Friday, January 11, 2008 2:11 PM
To: IUG INNOPAC List
Subject: Re: [IUG] Regular expression help
At 03:38 PM 01/11/2008, Andrew wrote:
>Sorry, this should have been
>..[^(je)].
Negative matching makes my brain go a little fuzzier than usual, but
I think that when you start putting values inside the square brackets
to indicate a range of characters, all but the caret are literal
values. So in this regex you'd be saying that there's a pattern
match when there's any single character, then any single character,
then any single character that's not a j, an e, or an opening or
closing parens, then any single character. So while any location
codes that have the string "je" in positions 3 and 4 of the code
would definitely not match (which is desired), there's a pretty large
universe of other strings that would also not match, which is NOT
desired. Examples: aajjb, aaejb, aaeeb, aajb, aaeb, (where a and b
can be any character) and anything three characters or less.
Or am I fuzzier than I think?
I think John Boggs' suggestion of combining several expressions in
create lists might be the only way to do something like this. Seems
vaguely reminiscent of the discussion about the area code search a
couple of months (?) back.
Bob Duncan
~!~!~!~!~!~!~!~!~!~!~!~!~
Robert E. Duncan
Systems Librarian
Editor of IT Communications
Lafayette College
Easton, PA 18042
duncanr at lafayette dot edu
http://www.library.lafayette.edu/
--
This message was distributed through the Innovative Users Group INNOPAC
list
Public replies: INNOPAC at innopacusers dot org
Update your subscription options:
http://innopacusers.org/mailman/listinfo/innopac