Re: Not exactly a dbi question

2006-04-05 Thread Paul DuBois
On 4/5/06 14:07, "Jonathan Mangin" <[EMAIL PROTECTED]> wrote: > > - Original Message - > From: "Dr.Ruud" <[EMAIL PROTECTED]> > To: > Sent: Wednesday, April 05, 2006 11:53 AM > Subject: Re: Not exactly a dbi question > > >>

Re: Not exactly a dbi question

2006-04-05 Thread Jonathan Mangin
- Original Message - From: "Dr.Ruud" <[EMAIL PROTECTED]> To: Sent: Wednesday, April 05, 2006 11:53 AM Subject: Re: Not exactly a dbi question > Paul DuBois schreef: > > > UPDATE tbl_name SET col_name = 0 WHERE col_name = 0; > > > > If you&

Re: Not exactly a dbi question

2006-04-05 Thread Dr.Ruud
Paul DuBois schreef: > UPDATE tbl_name SET col_name = 0 WHERE col_name = 0; > > If you've selected the rows-changed count, $sth->rows() will always > return 0, because the statement doesn't actually change any col_name > value from its current value. That would be an odd optimization. The update

Re: Not exactly a dbi question

2006-04-05 Thread Paul DuBois
aul DuBois [mailto:[EMAIL PROTECTED] >>>> Sent: Wednesday, April 05, 2006 10:41 AM >>>> To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org >>>> Subject: Re: Not exactly a dbi question [snip] >>>>>>> >>>>>>> Sorry, I'v

RE: Not exactly a dbi question

2006-04-05 Thread Garrett, Philip \(MAN-Corporate\)
>-Original Message- >From: Paul DuBois [mailto:[EMAIL PROTECTED] >Sent: Wednesday, April 05, 2006 10:56 AM >To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org >Subject: Re: Not exactly a dbi question > >On 4/5/06 9:46, "Garrett, Philip (MAN-Corporate)&q

Re: Not exactly a dbi question

2006-04-05 Thread Paul DuBois
On 4/5/06 9:46, "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]> wrote: > > >> -Original Message- >> From: Paul DuBois [mailto:[EMAIL PROTECTED] >> Sent: Wednesday, April 05, 2006 10:41 AM >> To: Garrett, Philip (MAN-Corporate); dbi-us

RE: Not exactly a dbi question

2006-04-05 Thread Garrett, Philip \(MAN-Corporate\)
>-Original Message- >From: Paul DuBois [mailto:[EMAIL PROTECTED] >Sent: Wednesday, April 05, 2006 10:41 AM >To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org >Subject: Re: Not exactly a dbi question >[snip] >>>> >>>> Sorry, I've

Re: Not exactly a dbi question

2006-04-05 Thread Paul DuBois
gt;>> Sent: Tuesday, April 04, 2006 4:20 PM >>>> To: Jonathan Mangin; Garrett, Philip (MAN-Corporate); >>> dbi-users@perl.org >>>> Subject: Re: Not exactly a dbi question >>>> >>>> On 4/4/06 15:06, "Jonathan Mangin" <[EMAIL PROTEC

RE: Not exactly a dbi question

2006-04-05 Thread Garrett, Philip \(MAN-Corporate\)
>-Original Message- >From: Paul DuBois [mailto:[EMAIL PROTECTED] >Sent: Wednesday, April 05, 2006 2:55 AM >To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org >Subject: Re: Not exactly a dbi question > >On 4/4/06 15:31, "Garrett, Philip (MAN-Corporate)&q

Re: Not exactly a dbi question

2006-04-05 Thread Paul DuBois
On 4/5/06 7:35, "Jonathan Mangin" <[EMAIL PROTECTED]> wrote: > > - Original Message - > From: "Paul DuBois" <[EMAIL PROTECTED]> > To: "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]>; > > Sent: Wednesday, April 05,

Re: Not exactly a dbi question

2006-04-05 Thread Jonathan Mangin
- Original Message - From: "Paul DuBois" <[EMAIL PROTECTED]> To: "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]>; Sent: Wednesday, April 05, 2006 2:55 AM Subject: Re: Not exactly a dbi question > On 4/4/06 15:31, "Garrett, Philip (MAN

Re: Not exactly a dbi question

2006-04-04 Thread Paul DuBois
> dbi-users@perl.org >> Subject: Re: Not exactly a dbi question >> >> On 4/4/06 15:06, "Jonathan Mangin" <[EMAIL PROTECTED]> wrote: >> >>> Autocommit is on. Perhaps you're misunderstanding. An update is not >>> supposed to happen if the

Re: Not exactly a dbi question

2006-04-04 Thread Jonathan Mangin
Ah. Not broke, but poorly-tuned. Thanks Paul, and Philip for all your help. --Jon - Original Message - From: "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]> To: Sent: Tuesday, April 04, 2006 4:31 PM Subject: RE: Not exactly a dbi question > -Original

RE: Not exactly a dbi question

2006-04-04 Thread Garrett, Philip \(MAN-Corporate\)
> -Original Message- > From: Paul DuBois [mailto:[EMAIL PROTECTED] > Sent: Tuesday, April 04, 2006 4:20 PM > To: Jonathan Mangin; Garrett, Philip (MAN-Corporate); dbi-users@perl.org > Subject: Re: Not exactly a dbi question > > On 4/4/06 15:06, "Jonathan Mangin&

Re: Not exactly a dbi question

2006-04-04 Thread Paul DuBois
On 4/4/06 15:06, "Jonathan Mangin" <[EMAIL PROTECTED]> wrote: > Autocommit is on. Perhaps you're misunderstanding. > An update is not supposed to happen if the column to be > updated is equal to the data being stuffed into it. > I want $row to reflect that but $row is always 1 > even when an upda

Re: Not exactly a dbi question

2006-04-04 Thread Jonathan Mangin
- Original Message - From: "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]> To: Sent: Tuesday, April 04, 2006 3:52 PM Subject: RE: Not exactly a dbi question > > > > -Original Message- > > > From: Jonathan Mangin [mailto:[EMAIL PROT

RE: Not exactly a dbi question

2006-04-04 Thread Garrett, Philip \(MAN-Corporate\)
> > > > -Original Message- > > > From: Jonathan Mangin [mailto:[EMAIL PROTECTED] > > > Sent: Tuesday, April 04, 2006 3:14 PM > > > To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org > > > Subject: Re: Not exactly a dbi question >

Re: Not exactly a dbi question

2006-04-04 Thread Jonathan Mangin
- Original Message - From: "Garrett, Philip (MAN-Corporate)" <[EMAIL PROTECTED]> To: Sent: Tuesday, April 04, 2006 3:23 PM Subject: RE: Not exactly a dbi question > -Original Message- > From: Jonathan Mangin [mailto:[EMAIL PROTECTED] > Sent: Tuesda

RE: Not exactly a dbi question

2006-04-04 Thread Garrett, Philip \(MAN-Corporate\)
> -Original Message- > From: Jonathan Mangin [mailto:[EMAIL PROTECTED] > Sent: Tuesday, April 04, 2006 3:14 PM > To: Garrett, Philip (MAN-Corporate); dbi-users@perl.org > Subject: Re: Not exactly a dbi question > > > The execute() method returns the number

Re: Not exactly a dbi question

2006-04-04 Thread Jonathan Mangin
The execute() method returns the number of rows affected for DML (insert/update/delete) statements, e.g. my $rows = $sth->execute($sql) || die "can't update: " . $sth->errstr; print "Updated $rows rows.\n"; The "|| die" stuff still works even when 0 rows are affected because in that case

RE: Not exactly a dbi question

2006-04-04 Thread Mark Hedges
On Tue, 4 Apr 2006, Garrett, Philip (MAN-Corporate) wrote: > > -Original Message- > > From: Jonathan Mangin [mailto:[EMAIL PROTECTED] > > > > Hi all, > > > > I hope someone here can help me. > > > The execute() method returns the number of rows affected for DML > (insert/update/delete

RE: Not exactly a dbi question

2006-04-04 Thread Garrett, Philip \(MAN-Corporate\)
> -Original Message- > From: Garrett, Philip (MAN-Corporate) [mailto:[EMAIL PROTECTED] > Sent: Tuesday, April 04, 2006 10:52 AM > To: dbi-users@perl.org > Subject: RE: Not exactly a dbi question > > > -Original Message- > > From: Jonathan Mangin [mai

RE: Not exactly a dbi question

2006-04-04 Thread Garrett, Philip \(MAN-Corporate\)
> -Original Message- > From: Jonathan Mangin [mailto:[EMAIL PROTECTED] > Sent: Tuesday, April 04, 2006 10:37 AM > To: dbi-users@perl.org > Subject: Not exactly a dbi question > > Hi all, > > I hope someone here can help me. > > The DBD::mysql docs see

Not exactly a dbi question

2006-04-04 Thread Jonathan Mangin
Hi all, I hope someone here can help me. The DBD::mysql docs seem to say that mysql_affected_rows is still a viable attribute. I have: $sql = "update user set type = ?, last_name = ?, state_id = ?, org_id = ?,