Displaying 1 result from an estimated 1 matches for "typo_conn".
Did you mean:
typo3conf
2006 Jun 20
1
Extracting a connection out of ActiveRecord::Base
...sn''t work with Ruby DBI, otherwise
I''d use that.
The problem I have is that when I do the following (this is *not*
inside an object inheriting from any of the ActiveRecord stuff):
self.connection = ActiveRecord::Base.connection
if self.options.include?(:db_adapter)
typo_conn = ActiveRecord::Base.connection
ActiveRecord::Base.establish_connection(
:adapter => self.options[:db_adapter],
:host => self.options[:db_host],
:username => self.options[:db_username],
:password => self.options[:db_password],
:database =&g...