execute not seen on selectrow_* for suclassed DBI



Hi,

I have subclassed DBI and override many methods including prepare, execute and
select* although they are predominantly just passed on to DBI.

If I do:

my $sth->prepare(sql);
$sth->execute;

I see the prepare and execute and pass them on to DBI.

If I do:

$dbh->selectrow_array(sql);

I see prepare and pass it on, but do not see execute. In my case this is more
than an annoyance as I cannot see any bound parameter passed to execute.

e.g.

$selectrow_array = [
'select b from mytest where a = ?',
undef,
\1
];
prepare: select b from mytest where a = ?
!!! no execute here

Or, perhaps I'm doing something wrong.

Can anyone tell me if I should be seeing the execute when $dbh->select*** is
called? I think I should.

Thanks

Martin
--
Martin J. Evans
Easysoft Ltd, UK
http://www.easysoft.com

.



Relevant Pages

  • Re: DBI v2 - The Plan and How You Can Help
    ... I can see room for all of them, but all of this is really a DBD, not a DBI, issue. ... and some of them have to resort to search-n-replace in the SQL string at execute() time since the database doesn't have native support. ... ie, on Pg the STHs would be built before the DB is connected, and on Oracle they are built the first time they are used. ... well I am thinking of large program environments here where data dictionaries and generated SQL are the norm. ...
    (perl.dbi.users)
  • request for clarification, was (DBD::DB2 execute and finish problem)
    ... DBI documentation says execute on a an active statement should imply a finish ...
    (perl.dbi.users)
  • Re: Memory access problem with DBI or DBD-Mysql?
    ... It seems that the problems are only with the "do" method and not with the "execute", so I looked for the differences between them. ... I want to repeat that the problem manifest itself only under OpenBSD because of it's memory management that cause the program to segfault if try to access a non allocated memory. ... I'm using DBI 1.45 and DBD-Mysql 2.9008. ...
    (perl.dbi.users)
  • Re: DBI v2 - The Plan and How You Can Help
    ... Darren Duncan wrote: ... of them, but all of this is really a DBD, not a DBI, issue. ... > DBD to decide whether to actually do anything with it immediately or not. ... a database) in your BEGIN block, and execute thousands of times after that. ...
    (perl.dbi.users)
  • Re: Tracing SQL queries done via DBI (mod_perl)
    ... There is a tracemethod on DBI, however, it does not properly print ... dbd_st_prepare calling count_params ... <- execute= 1 at dbitest.pl line 10 ... <- DESTROY= undef during global destruction ...
    (comp.lang.perl.misc)