Re: what does $dbh->execute return for a select?
- From: martin.evans@xxxxxxxxxxxx (Martin J. Evans)
- Date: Mon, 22 May 2006 09:11:12 +0100 (BST)
On 19-May-2006 Tim Bunce wrote:
On Fri, May 19, 2006 at 07:24:13PM +0100, Martin J. Evans wrote:
but I'm doing a select * from table and getting back a true value
which is 1. I thought for a successful select, execute would return
0E0 (which is true) but not 1. I was hoping to use true but not
0E0 to identify a non-select statement that affected rows.
You can use $sth->{NUM_OF_FIELDS} to tell if it's a SELECT statement.
Tim.
Thanks and sorry - what comes from working too late.
I've made that change but I still don't think execute is returning what the
documentation suggests it should.
Martin
--
Martin J. Evans
Easysoft Ltd, UK
http://www.easysoft.com
.
- References:
- Re: what does $dbh->execute return for a select?
- From: Tim Bunce
- Re: what does $dbh->execute return for a select?
- Prev by Date: Stored Procedures that return a recordset
- Next by Date: [ANNOUNCE] DBix::Chart 0.05, DBD::Chart 0.82
- Previous by thread: Re: what does $dbh->execute return for a select?
- Next by thread: Stored Procedures that return a recordset
- Index(es):
Relevant Pages
|