我看了前面发的一些帖子,按照上面的方法改了下代码,但是报错,我是新手,请各位前辈帮帮忙,先谢谢大家了
这是database.php中的代码
$db['default']['hostname'] = "127.0.0.1/";
$db['default']['username'] = "username";
$db['default']['password'] = "pwd";
$db['default']['database'] = "orcl";
$db['default']['dbdriver'] = "oci8";
$db['default']['dbprefix'] = "";
$db['default']['pconnect'] = TRUE;
$db['default']['db_debug'] = TRUE;
$db['default']['cache_on'] = FALSE;
$db['default']['cachedir'] = "";
$db['default']['char_set'] = "utf8";
$db['default']['dbcollat'] = "utf8_general_ci";
这是database/drivers/oci8/oci8_driver.php中修改的 _set_stmt_id方法的代码
function _set_stmt_id($sql)
{
if ( ! is_resource($this->stmt_id))
{
$this->stmt_id = ociparse($this->conn_id, $this->_prep_query($sql));
}
$this->stmt_id = ociparse($this->conn_id, $this->_prep_query($sql));
}
页面报的错误是
A PHP Error was encountered
Severity: Notice
Message: Use of undefined constant OCI_COMMIT_ON_SUCCESS - assumed 'OCI_COMMIT_ON_SUCCESS'
Filename: database/DB.php
Line Number: 133
请高手帮帮忙,这是哪的问题啊? |