Download & Extend

Oracle driver compatibility and general 7.x driver issues

Project:DBTNG
Version:6.x-1.x-dev
Component:Code
Category:support request
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

I'm recently studing an issue of compatibility with the 7.x oracle driver and i would like to know your opinion:

http://drupal.org/node/622336#comment-2802180

I think it should be mostly work for your module. (IMUO)

Thanks,
Andrea

Comments

#1

Status:active» postponed

Yeah, I've discussed this with the interested parties, and they seem to be able to make it work for their use cases. I don't think there's anything else that I need to follow up with here, as a few of the items I can't really do much about, such as the paths in the Oracle driver.

#2

Status:postponed» needs review

This patch adds a hook_requirements() to check that all the PDO drivers are available for the connection strings in $db_url.

AttachmentSize
hook-requirements.patch 1.57 KB

#3

I've updated DBTNG to introduce a dependency on Autoload 2.x and I *think* this should allow turning other DB drivers into modules, as long as they declare all their files in their .info. This is only for D6 of course. I'll try to get a Oracle testing instance up in the next few days to test this.

#4

I'm using DBTNG and the Oracle driver to connect to an external database on a 6.x site (following instructions at Connecting to an external Oracle instance with DBTNG), and I'm getting errors following the latest DBTNG upgrades. With dbtng-6.x-1.0-alpha7 I get the following fatal error: Class 'Database' not found in ... modules/dbtng/dbtng.module on line 324.

If this isn't the best place to post this, I'm happy to open a new issue. Thanks.

#5

I had the same issue. It was related to the Autoload module. Make sure to get the correct version (6.x-2.0-rc1 or higher) and activate it before activating dbtng.

Regards.

#6

Category:feature request» support request
Status:needs review» active

Hi,

I'm using DBTNG along with Oracle driver to connect to an external database on a 6.x site. I created oracle folder under dbtng\database and copied all the .inc files from Oracle driver into this folder. I also uncommented the pdo extensions from the php.ini file.

The query I am writing is -
dbtng_set_active('my_oracle_db');
$query = 'SELECT * FROM ...';
$arguments = array();
$options = array('target' => 'my_oracle_db', 'fetch' => PDO::FETCH_ASSOC,);
$results = dbtng_query($query, $arguments, $options);
foreach($results as $record){
$output .= "This is from Oracle".$record->RECOMMENDED_FULL_NAME;
}
dbtng_set_active('default');

But I am getting this error:-
Fatal error: Class DatabaseConnection_oracle contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (DatabaseConnection::version) in \sites\all\modules\dbtng\database\oracle\database.inc on line 613

Would appreciate any help. Also please let me know if this is the correct way of querying using the dbtng module.

Thanks
rpandey

#7

I have the same problem as rpandey1. Are we doing something wrong?!?

#8

So I was using older versions of those modules when I posted how I did it, seems like things have changed a bit since then.

Abstract methods are a feature of object oriented programming (http://php.net/manual/en/language.oop5.abstract.php). I can't go into all the details here, but it sounds like PHP is complaining that a class with an abstract method is being called. The resolve it, either the whole class needs to be abstract, or the whole class needs to not contain any abstract methods at all. Check Class DatabaseConnection_oracle and see if you can remove its abstract method or get rid of the abstract keyword.

nobody click here