yiic shell / oci driver

I am having problems to create a model using yiic shell against an Oracle database.

This stand-alone code using PDO works:




<?php

try {

    $pdo = new PDO('oci:dbname=//IP.ADD.RE.SS:1521/schemaname', 'user', 'password');

} catch (PDOException $e) {

    die('Connection failed: ' . $e->getMessage());

}

$sql = 'SELECT * FROM TRACKERDB.T_QX_USERS';

$result = $pdo->query($sql);

while($row = $result->fetch(PDO::FETCH_ASSOC)) {

    var_dump($row);

}

?>



In the yiic shell, I receive this:




>> model TrackerUser TRACKERDB.T_QX_USERS

Warning: the table 'TRACKERDB.T_QX_USERS' does not exist in the database.



The db config looks like:




'db'=>array(

   'connectionString' => 'oci:dbname=//IP.ADD.RE.SS:1521/schemaname',

   'username' => 'user',

   'password' => 'password'

),



Any help would be appreciated!

Regards,

Joachim

Not sure if this will help you but I have posted some oracle issues I found here:

http://www.yiiframework.com/forum/index.php?/topic/11306-oci8-with-cdbconnection/

First there is a private variable (private $_defaultSchema = ‘’; ) at the top of your “<YII_HOME>/framework/db/schema/oci/COciSchema.php” file. You may want to set that to “TRACKERDB” so in your model generator you can simply say “T_QX_USERS” as table name and not “TRACKERDB.T_QX_USERS”.

I may be wrong on that but it is worth a shot.

Also, in the same file, I have seen mention of changing two functions to not quote table or column names.

That can be read here:

http://www.yiiframework.com/forum/index.php?/topic/7904-yii-1-1-1-oci-does-not-have-to-quote-names/page__p__43866__hl__COciSchema.php#entry43866