Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Duane Bronson
Holy mother of pe(a)rl! Here's your solution on the half shell. Sorry for the bad puns - I'll clam up now. grep -P -i '^125.*?baxp\.caed.*?\n250' Documentation: http://www.gnu.org/software/grep/doc/grep_6.html#SEC6 from gnu's grep --help -P, --perl-regexp PATTERN is a Perl regular

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ranga Nathan
Ok Kripa and Ben. It is a done deal. Why settle with the shell when you can get the pe(a)rl :-) Thanks. This script does not have to be super efficient but it has to be correct. I vote for Perl then. __ Ranga Nathan / CSG Systems Programmer - Specialist;

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ben Tilly
On 10/19/05, Ranga Nathan <[EMAIL PROTECTED]> wrote: > I need to check ftp logs (see below) for successful transfer of files. > This is a bash script someone else wrote and I need to modify it. I want > to use a Perl style regex like > > /^125.*?baxp\.caed.*?\n250/i > > in any ?grep or sed or

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Kripa Sundar
Dear Ranga, Two clarifications on my previous email. I wrote: > If the perl invocation is your performance bottleneck, that is a > pleasant problem to deal with. What I meant to write is this: > If the overhead of invoking perl is your performance bottleneck, that is a > pleasant problem to

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Kripa Sundar
Dear Ranga, > I tried grep and egrep - they seem to match only one line at a time. I am > unable to match for \n inside the pattern. > > What shell utility would do it? I dont want to bring in the perl > interpreter just for this! Please *do*! If the perl invocation is your performance

[Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ranga Nathan
I need to check ftp logs (see below) for successful transfer of files. This is a bash script someone else wrote and I need to modify it. I want to use a Perl style regex like /^125.*?baxp\.caed.*?\n250/i in any ?grep or sed or awk whichever can do this. I tried grep and egrep - they seem

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Uri Guttman
> "DB" == Dan Boger <[EMAIL PROTECTED]> writes: DB> On Wed, Oct 19, 2005 at 02:09:09PM -0400, Uri Guttman wrote: >> i assume that your class inherits from class::dbi and you loaded that >> abstract plugin. DB> Yup. >> beyond this i would actually look at the code which is barfing

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Ben Tilly
On 10/19/05, Dan Boger <[EMAIL PROTECTED]> wrote: > On Wed, Oct 19, 2005 at 02:09:09PM -0400, Uri Guttman wrote: [...] > > beyond this i would actually look at the code which is barfing about > > an array ref and see what it is getting and where that data comes from > > (hopefully your code/data).

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Dan Boger
On Wed, Oct 19, 2005 at 02:09:09PM -0400, Uri Guttman wrote: > i assume that your class inherits from class::dbi and you loaded that > abstract plugin. Yup. > beyond this i would actually look at the code which is barfing about > an array ref and see what it is getting and where that data comes

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Uri Guttman
> "DB" == Dan Boger <[EMAIL PROTECTED]> writes: DB> On Wed, Oct 19, 2005 at 01:04:40PM -0400, Uri Guttman wrote: >> > "DB" == Dan Boger <[EMAIL PROTECTED]> writes: DB> my @res = Peeron2::Sets->search_where(ID => $setid); >> >> from the class::dbi docs: >> >> my @music =

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Dan Boger
On Wed, Oct 19, 2005 at 01:17:19PM -0400, Jeremy Muhlich wrote: > On Wed, 2005-10-19 at 12:42 -0400, Dan Boger wrote: > > my @res = Peeron2::Sets->search_where(ID => $setid); > > Is 'id' the primary key of the table? If so, you should be using > retrieve($id) instead of search_where. Right -

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Dan Boger
On Wed, Oct 19, 2005 at 01:04:40PM -0400, Uri Guttman wrote: > > "DB" == Dan Boger <[EMAIL PROTECTED]> writes: > DB> my @res = Peeron2::Sets->search_where(ID => $setid); > > from the class::dbi docs: > > my @music = Music::CD->search_where( > artist => [ 'Ozzy', 'Kelly' ], >

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Jeremy Muhlich
On Wed, 2005-10-19 at 12:42 -0400, Dan Boger wrote: > > What are you passing to the offending search_where() call in > > Peeron2/Sets.pm? > > Just a single search param: > > my @res = Peeron2::Sets->search_where(ID => $setid); Is 'id' the primary key of the table? If so, you should be using

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Uri Guttman
> "DB" == Dan Boger <[EMAIL PROTECTED]> writes: >> > : Not an ARRAY reference at /usr/home/peeron/lib/modules/Class/DBI.pm line 1126. >> >at /usr/home/peeron/lib/modules/Class/DBI/AbstractSearch.pm line 32 >> >> What are you passing to the offending search_where() call in >>

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Dan Boger
On Wed, Oct 19, 2005 at 11:34:36AM -0400, Jeremy Muhlich wrote: > On Wed, 2005-10-19 at 09:55 -0400, Dan Boger wrote: > > Peeron2::Sets can't SELECT id, id, setnumber, setrev, name, theme, year, > > pcs, figs, picture, msrp, instructions, inventory > > FROM SETS > > WHERE ( ID = ? ) > >

Re: [Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Jeremy Muhlich
On Wed, 2005-10-19 at 09:55 -0400, Dan Boger wrote: > Peeron2::Sets can't SELECT id, id, setnumber, setrev, name, theme, year, > pcs, figs, picture, msrp, instructions, inventory > FROM SETS > WHERE ( ID = ? ) > : Not an ARRAY reference at /usr/home/peeron/lib/modules/Class/DBI.pm line

[Boston.pm] Social Meeting with brian d foy, Thu Oct 20

2005-10-19 Thread Ronald J Kimball
Boston.pm Social Meeting with brian d foy! Thursday, October 20, at 8pm Red Bones in Davis Square, Somerville Please RSVP to me ASAP if you plan on attending - rjk-bostonpm(at)tamias.net. Restaurant Website & Directions: http://www.redbones.com/ http://www.redbones.com/directionsmain.html

Re: [Boston.pm] Social Meeting on Thursday with brian d foy

2005-10-19 Thread Ronald J Kimball
On Wed, Oct 19, 2005 at 09:44:09AM -0400, [EMAIL PROTECTED] wrote: > hi > > ( 05.10.19 09:17 -0400 ) Ronald J Kimball: > > Any other votes for 8pm rather than 7:30pm? > > um, later is better for me. i prolly won't get there till 9-ish > Well, I don't think we can start as late as 9... Let's

[Boston.pm] Class::DBI sporadic errors

2005-10-19 Thread Dan Boger
Anyone here have any experience with Class::DBI? I'm starting to convert my custom DBI class to use Class::DBI, but I'm running into weird errors. One of my pages looks up multiple objects, one by one, from a queue. this was working ok (even after converting to CDBI), but now, after

Re: [Boston.pm] Social Meeting on Thursday with brian d foy

2005-10-19 Thread Ronald J Kimball
On Wed, Oct 19, 2005 at 12:47:07AM -0400, Kenneth A Graves wrote: > On Tue, 2005-10-18 at 23:16, Ronald J Kimball wrote: > > > > I figured I would start collecting RSVPs once we had agreed on a time. > > I'll probably be there, but 8pm would be better for me. > Any other votes for 8pm rather