already existing database handles

[prev] [thread] [next] [Date index for 2005/06/17]

From: moreejt
Subject: already existing database handles
Date: 17:01 on 17 Jun 2005
Hello,
  I have been searching the mailing list and the web for an answer to this but nothing has presented itself.

  I want to use Class::DBI in a framework which already has database connections open.  It seems from the docs that Class::DBI wants to establish the connection in new().  Is there a way to tell it to use an already existing database handle?

I thought about creating the class::dbi object with fake data and then setting $obj->{db_Main} manually but seems like a nasty hack and doesn't seem to work anyway.  

Ideally, I want to be able to tell class::dbi in new to use a passed in dbhandle.  soemthing like

Class::DBI->new(db_Main => $dbh, namespace => . . . etc

already existing database handles
moreejt 17:01 on 17 Jun 2005

Re: already existing database handles
Edward J. Sabol 18:39 on 17 Jun 2005

Re: already existing database handles
JT Moree 02:02 on 19 Jun 2005

Re: already existing database handles
Sean Davis 03:15 on 19 Jun 2005

Re: already existing database handles
JT Moree 21:02 on 19 Jun 2005

Generated at 16:37 on 28 Jul 2005 by mariachi v0.52