Skip Menu |

This queue is for tickets about the DBI CPAN distribution.

Report information
The Basics
Id: 4555
Status: resolved
Priority: 0/
Queue: DBI

People
Owner: Nobody in particular
Requestors: spoon [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.39
Fixed in: (no value)



Subject: Missing execute in docs
In fetchall_hashref: $dbh->{FetchHashKeyName} = 'NAME_lc'; $sth = $dbh->prepare("SELECT FOO, BAR, ID, NAME, BAZ FROM TABLE"); $hash_ref = $sth->fetchall_hashref('id'); print "Name for id 42 is $hash_ref->{42}->{name}\n"; That should have an << $sth->execute; >> between the prepare and the fetchall_hashref. cheers, -- Iain.
Date: Wed, 3 Dec 2003 23:32:36 +0000
From: Tim Bunce <Tim.Bunce [...] pobox.com>
To: Iain Truskett via RT <bug-DBI [...] rt.cpan.org>
CC: "AdminCc of cpan Ticket #4555": ;
Subject: Re: [cpan #4555] Missing execute in docs
RT-Send-Cc:
Thanks. Tim. On Wed, Dec 03, 2003 at 06:51:24AM -0500, Iain Truskett via RT wrote: Show quoted text
> > This message about DBI was sent to you by SPOON <SPOON@cpan.org> via rt.cpan.org > > Full context and any attached attachments can be found at: > <URL: https://rt.cpan.org/Ticket/Display.html?id=4555 > > > In fetchall_hashref: > > $dbh->{FetchHashKeyName} = 'NAME_lc'; > $sth = $dbh->prepare("SELECT FOO, BAR, ID, NAME, BAZ FROM TABLE"); > $hash_ref = $sth->fetchall_hashref('id'); > print "Name for id 42 is $hash_ref->{42}->{name}\n"; > > That should have an << $sth->execute; >> between the prepare and > the fetchall_hashref. > > > cheers, > -- > Iain.
Thanks. Will be fixed in DBI 1.40