Re: Regex

2005-09-27 Thread $Bill Luebkert
Chris Wagner wrote: > At 05:11 PM 9/27/05 -0700, $Bill Luebkert wrote: > >>\s* means to grab any WS at the current position (including the case where >> there is none). >> >>\s*? means 0 or 1 of the above which is totally meaningless - you've already >> eaten all the WS with the \s*, so in my

Re: Regex

2005-09-27 Thread Chris Wagner
At 05:11 PM 9/27/05 -0700, $Bill Luebkert wrote: >\s* means to grab any WS at the current position (including the case where >there is none). > >\s*? means 0 or 1 of the above which is totally meaningless - you've already >eaten all the WS with the \s*, so in my opinion the ? is redundant t

Re: Regex

2005-09-27 Thread $Bill Luebkert
Chris Wagner wrote: > At 12:08 AM 9/27/05 -0700, robert johnson wrote: > >>and by the way, *? is redundant. >>* means zero or more. >>? means zero or one. > > > > Actually the *? construct is not a redundancy. It calls for a minimal match > rather than a maximal match, which is the default.

RE: Processing numbered files sequentially -- 10,000 at a time

2005-09-27 Thread McGlinchy, Alistair
Craig, > Is there a loop I can use that will process the first 10,000 > files, then > exit; then the next 10,000 files, then exit; and so on until > all files > have been processed? The exiting is so I can run a SQL Server job to > insert the processed files into SQL Server. Like every other

Re: Regex

2005-09-27 Thread Chris Wagner
At 12:08 AM 9/27/05 -0700, robert johnson wrote: >and by the way, *? is redundant. >* means zero or more. >? means zero or one. Actually the *? construct is not a redundancy. It calls for a minimal match rather than a maximal match, which is the default. Although it was useless in the example.

Re: Processing numbered files sequentially -- 10,000 at a time

2005-09-27 Thread Craig Cardimon
Chris Wagner wrote: At 02:46 PM 9/26/05 -0400, Craig Cardimon wrote: I am reading in portions of large files into string variables. The number of and size of the files vary by month. Right now I'm working with nearly 70,000 files, the largest of which is 7 GB. Not all files are processed, but

Re: Regex

2005-09-27 Thread robert johnson
David Budd wrote: I thought this was working, but my logs just showed a case where it seems not to do what I want. Why does: $OK_body=($body=~/library\s*?card\D*?(\d{7})\D/i) ; Not become true when $body contains: Library Card: 0240742 i'd bet that it passes when you have some whitespace af