Skip Menu |

This queue is for tickets about the DBIx-DataModel CPAN distribution.

Report information
The Basics
Id: 120719
Status: open
Priority: 0/
Queue: DBIx-DataModel

People
Owner: Nobody in particular
Requestors: aireland [...] lbl.gov
Cc:
AdminCc:

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



Subject: -result_as => 'sth' does not return DBI statement handle
Date: Thu, 23 Mar 2017 07:32:33 -0700
To: bug-DBIx-DataModel [...] rt.cpan.org
From: Amelia Ireland <aireland [...] lbl.gov>
According to the documentation: `-result_as => 'sth'`: The result will be an executed DBI statement handle. Then it is up to the caller to retrieve data rows using the DBI API. If needed, these rows can be later blessed into appropriate objects through bless_from_DB(). I expected to be able to do (e.g.) `$sth->fetchall_arrayref`, but the object returned is a DBIx::DataModel::Statement. Is it possible to access the DBI statement handle via the DBIx::DataModel::Statement object? <https://metacpan.org/pod/distribution/DBIx-DataModel/lib/DBIx/DataModel/Doc/Reference.pod#sql>
On Thu Mar 23 10:35:15 2017, aireland@lbl.gov wrote: Show quoted text
> According to the documentation: `-result_as => 'sth'`: > > The result will be an executed DBI statement handle. Then it is up to > the > caller to retrieve data rows using the DBI API. If needed, these rows > can > be later blessed into appropriate objects through bless_from_DB(). > > I expected to be able to do (e.g.) `$sth->fetchall_arrayref`, but the > object returned is a DBIx::DataModel::Statement. > > Is it possible to access the DBI statement handle via the > DBIx::DataModel::Statement object? > <https://metacpan.org/pod/distribution/DBIx- > DataModel/lib/DBIx/DataModel/Doc/Reference.pod#sql>