I am trying to do write a search comparison between to part numbers.... $found = 1 if $string1 =~ /$string2/g;
I want to know if $string2 occurs within $string1. Basic enough ... however, I am finding that at times $string2 contains characters such as: ** and (+ABC etc. and this is giving errors in the REGEX such as Quantifier follows nothing before HERE mark in regex because these characters throw off the regex... I could write a cleanup routine to strip out characters like this so that $string2 never contains them -- but I wanted to know if there is something I can do within the REGEX itself to tell it not interpret anthing found within $string2 as anything other than the characters for the pattern and not some special meaning. I tried using /"$string2"/g and /\'$string2\'/g ... this did not work and I believe it may not be on the right track... Thanks for any help... John ===== John V. Pataki Logged in to my Yahoo Mail account on the web. _______________________________________________ ActivePerl mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
