ZF-4943: Zend_Db_Adapter_Oracle does not support connection charset
Description
oci_connect is capable of handling a connection charset parameter, whereas the current implementation of Zend_Db_Adapter_Oracle is not.
This can be easily implemented by altering protected _connect() of Zend_Db_Adapter_Oracle:
if (isset($this->_config['dbname'])) {
if (isset($this->_config['charset'])) {
$this->_connection = @oci_connect(
$this->_config['username'],
$this->_config['password'],
$this->_config['dbname'],
$this->_config['charset']);
} else {
$this->_connection = @oci_connect(
$this->_config['username'],
$this->_config['password'],
$this->_config['dbname']);
}
} else {
if (isset($this->_config['charset'])) {
$this->_connection = @oci_connect(
$this->_config['username'],
$this->_config['password'],
null,
$this->_config['charset']);
} else {
$this->_connection = @oci_connect(
$this->_config['username'],
$this->_config['password']);
}
}
Comments
Posted by Mickael Perraud (mikaelkael) on 2008-11-19T04:30:51.000+0000
See also ZF-1541
Posted by Mickael Perraud (mikaelkael) on 2008-11-19T04:32:06.000+0000
Duplicates