Re: any size limitation as to the size of a query statement?

2001-06-21 Thread Don Read
On 21-Jun-01 Chris Petersen wrote: >> here, @ids is the array, delete in chunks of 64: >> while ( my(@id)= splice(@ids,0,64)) { >> $qry="DELETE FROM master WHERE master_id in (".join(',',@id).")"; >> SQLQuery($qry); >> } > > I thought about this, too.. But Mark said that he needed to delete

Re: any size limitation as to the size of a query statement?

2001-06-21 Thread Chris Petersen
> here, @ids is the array, delete in chunks of 64: > while ( my(@id)= splice(@ids,0,64)) { > $qry="DELETE FROM master WHERE master_id in (".join(',',@id).")"; > SQLQuery($qry); > } I thought about this, too.. But Mark said that he needed to delete from the table where the ID's don't match.

RE: any size limitation as to the size of a query statement?

2001-06-21 Thread Mark A. Sharkey
gt; To: Chris Petersen > Cc: [EMAIL PROTECTED]; Mark A. Sharkey > Subject: Re: any size limitation as to the size of a query statement? > > > > On 21-Jun-01 Chris Petersen wrote: > > Why not do something like: > > > > my $q = "DELETE FROM master WHERE mast

Re: any size limitation as to the size of a query statement?

2001-06-21 Thread Don Read
On 21-Jun-01 Chris Petersen wrote: > Why not do something like: > > my $q = "DELETE FROM master WHERE master_id NOT IN ("; > $q .= join(',', @masteridarray); > $q .= ')'; > $dbi_dbh->do($q); > > Though this will obviously fall into the same size limitations that you were > doing

Re: Re: any size limitation as to the size of a query statement?

2001-06-21 Thread Bill Marrs
My code generates a large query. I had to increase the size of "max_allowed_packet" so that this query would work. I have this in my /etc/my.cnf file: set-variable = max_allowed_packet=2097152 -bill - Before posting, please

Re: any size limitation as to the size of a query statement?

2001-06-21 Thread Chris Petersen
Why not do something like: my $q = "DELETE FROM master WHERE master_id NOT IN ("; $q .= join(',', @masteridarray); $q .= ')'; $dbi_dbh->do($q); Though this will obviously fall into the same size limitations that you were doing, but it should execute a lot faster, and be a bit sma