Lines Matching refs:dbh

34 static int pdo_oci_fetch_error_func(pdo_dbh_t *dbh, pdo_stmt_t *stmt, zval *info) /* {{{ */  in pdo_oci_fetch_error_func()  argument
36 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in pdo_oci_fetch_error_func()
58 ub4 _oci_error(OCIError *err, pdo_dbh_t *dbh, pdo_stmt_t *stmt, char *what, sword status, int isini… in _oci_error() argument
62 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in _oci_error()
65 pdo_error_type *pdo_err = &dbh->error_code; in _oci_error()
77 pefree(einfo->errmsg, dbh->is_persistent); in _oci_error()
88 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
98 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
103 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
107 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
111 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
115 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
119 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
123 einfo->errmsg = pestrdup(tmp_buf, dbh->is_persistent); in _oci_error()
158 dbh->is_closed = 1; in _oci_error()
173 pefree(H->einfo.errmsg, dbh->is_persistent); in _oci_error()
176 H->einfo.errmsg = einfo->errmsg ? pestrdup(einfo->errmsg, dbh->is_persistent) : NULL; in _oci_error()
177 strcpy(dbh->error_code, stmt->error_code); in _oci_error()
182 if (!dbh->methods) { in _oci_error()
190 static int oci_handle_closer(pdo_dbh_t *dbh) /* {{{ */ in oci_handle_closer() argument
192 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_closer()
233 pefree(H->einfo.errmsg, dbh->is_persistent); in oci_handle_closer()
237 pefree(H, dbh->is_persistent); in oci_handle_closer()
243 static int oci_handle_preparer(pdo_dbh_t *dbh, const char *sql, size_t sql_len, pdo_stmt_t *stmt, z… in oci_handle_preparer() argument
245 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_preparer()
270 strcpy(dbh->error_code, stmt->error_code); in oci_handle_preparer()
317 static zend_long oci_handle_doer(pdo_dbh_t *dbh, const char *sql, size_t sql_len) /* {{{ */ in oci_handle_doer() argument
319 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_doer()
345 (dbh->auto_commit && !dbh->in_txn) ? OCI_COMMIT_ON_SUCCESS : OCI_DEFAULT); in oci_handle_doer()
361 static int oci_handle_quoter(pdo_dbh_t *dbh, const char *unquoted, size_t unquotedlen, char **quote… in oci_handle_quoter() argument
398 static int oci_handle_begin(pdo_dbh_t *dbh) /* {{{ */ in oci_handle_begin() argument
405 static int oci_handle_commit(pdo_dbh_t *dbh) /* {{{ */ in oci_handle_commit() argument
407 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_commit()
419 static int oci_handle_rollback(pdo_dbh_t *dbh) /* {{{ */ in oci_handle_rollback() argument
421 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_rollback()
433 static int oci_handle_set_attribute(pdo_dbh_t *dbh, zend_long attr, zval *val) /* {{{ */ in oci_handle_set_attribute() argument
436 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_set_attribute()
441 if (dbh->in_txn) { in oci_handle_set_attribute()
449 dbh->in_txn = 0; in oci_handle_set_attribute()
452 dbh->auto_commit = (unsigned int)lval? 1 : 0; in oci_handle_set_attribute()
551 static int oci_handle_get_attribute(pdo_dbh_t *dbh, zend_long attr, zval *return_value) /* {{{ */ in oci_handle_get_attribute() argument
553 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in oci_handle_get_attribute()
605 ZVAL_BOOL(return_value, dbh->auto_commit); in oci_handle_get_attribute()
620 static int pdo_oci_check_liveness(pdo_dbh_t *dbh) /* {{{ */ in pdo_oci_check_liveness() argument
622 pdo_oci_db_handle *H = (pdo_oci_db_handle *)dbh->driver_data; in pdo_oci_check_liveness()
675 static int pdo_oci_handle_factory(pdo_dbh_t *dbh, zval *driver_options) /* {{{ */ in pdo_oci_handle_factory() argument
686 php_pdo_parse_data_source(dbh->data_source, dbh->data_source_len, vars, 4); in pdo_oci_handle_factory()
688 H = pecalloc(1, sizeof(*H), dbh->is_persistent); in pdo_oci_handle_factory()
689 dbh->driver_data = H; in pdo_oci_handle_factory()
691 dbh->skip_param_evt = in pdo_oci_handle_factory()
755 if (!dbh->username && vars[2].optval) { in pdo_oci_handle_factory()
756 dbh->username = pestrdup(vars[2].optval, dbh->is_persistent); in pdo_oci_handle_factory()
759 if (dbh->username) { in pdo_oci_handle_factory()
761 dbh->username, (ub4) strlen(dbh->username), in pdo_oci_handle_factory()
770 if (!dbh->password && vars[3].optval) { in pdo_oci_handle_factory()
771 dbh->password = pestrdup(vars[3].optval, dbh->is_persistent); in pdo_oci_handle_factory()
774 if (dbh->password) { in pdo_oci_handle_factory()
776 dbh->password, (ub4) strlen(dbh->password), in pdo_oci_handle_factory()
805 dbh->methods = &oci_methods; in pdo_oci_handle_factory()
806 dbh->alloc_own_columns = 1; in pdo_oci_handle_factory()
807 dbh->native_case = PDO_CASE_UPPER; in pdo_oci_handle_factory()
819 oci_handle_closer(dbh); in pdo_oci_handle_factory()