I am having trouble with a regex in perl.
I have an array that looks like this:
Abilene,KS,67410,1019 2000 Ave,38.88254,-97.20204,Grant Town Fire Dist
*Arlington,KS,67514,100 W Main St,Reno County Fire Dist 4
Abilene,KS,67410,1463 3325 Ave,39.079136,-97.1181,Sherman Township
Fire District
*Beattie,KS,66406,305 Whiting St,Beattie Rural Fire District No 3
Agra,KS,67621,1752 E 1100 Rd,39.749302,-99.12297,Phillips County Rural
Fire District 3a

I want to remove all of the (2) lines not containing a valid northern
lattitude within commas ie...  ,39.xxxxx,
This will not work for me in perl
$tempContent =~ s/^((?!,\d{1,2}\.\d{1,16},).)*$\n//g;

This works in UltraEdit:
^(?:(?!,\d{1,2}\.\d{1,16},).)*$\r\n

This works also with EditPadPro
^(?:(?!,\d{1,2}\.\d{1,16},).)*$\r\n
as does
^((?!,\d{2,3}\.\d{1,16},).)*$\r\n

It may be a simple fix but I cannot see it.
Thanks


-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to