Lines Matching refs:S

87 	pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data;  in firebird_stmt_dtor()  local
91 if (isc_dsql_free_statement(S->H->isc_status, &S->stmt, DSQL_drop)) { in firebird_stmt_dtor()
96 zend_hash_destroy(S->named_params); in firebird_stmt_dtor()
97 FREE_HASHTABLE(S->named_params); in firebird_stmt_dtor()
100 if (S->in_sqlda) { in firebird_stmt_dtor()
101 free_sqlda(S->in_sqlda); in firebird_stmt_dtor()
102 efree(S->in_sqlda); in firebird_stmt_dtor()
105 free_sqlda(&S->out_sqlda); in firebird_stmt_dtor()
106 efree(S); in firebird_stmt_dtor()
115 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_execute() local
116 pdo_firebird_db_handle *H = S->H; in firebird_stmt_execute()
123 …if ((*S->name || S->cursor_open) && isc_dsql_free_statement(H->isc_status, &S->stmt, DSQL_close)) { in firebird_stmt_execute()
126 S->cursor_open = 0; in firebird_stmt_execute()
129 if (S->out_sqlda.sqld) { in firebird_stmt_execute()
131 for (i = 0; i < S->out_sqlda.sqld; i++) { in firebird_stmt_execute()
132 XSQLVAR *var = &S->out_sqlda.sqlvar[i]; in firebird_stmt_execute()
141 if (S->statement_type == isc_info_sql_stmt_exec_procedure) { in firebird_stmt_execute()
142 …if (isc_dsql_execute2(H->isc_status, &H->tr, &S->stmt, PDO_FB_SQLDA_VERSION, S->in_sqlda, &S->out_… in firebird_stmt_execute()
145 } else if (isc_dsql_execute(H->isc_status, &H->tr, &S->stmt, PDO_FB_SQLDA_VERSION, S->in_sqlda)) { in firebird_stmt_execute()
154 switch (S->statement_type) { in firebird_stmt_execute()
159 if (isc_dsql_sql_info(H->isc_status, &S->stmt, sizeof ( info_count), in firebird_stmt_execute()
190 *S->name = 0; in firebird_stmt_execute()
191 S->cursor_open = S->out_sqlda.sqln && (S->statement_type != isc_info_sql_stmt_exec_procedure); in firebird_stmt_execute()
192 S->exhausted = !S->out_sqlda.sqln; /* There are data to fetch */ in firebird_stmt_execute()
208 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_fetch() local
209 pdo_firebird_db_handle *H = S->H; in firebird_stmt_fetch()
214 } else if (!S->exhausted) { in firebird_stmt_fetch()
215 if (S->statement_type == isc_info_sql_stmt_exec_procedure) { in firebird_stmt_fetch()
217 S->exhausted = 1; in firebird_stmt_fetch()
220 if (isc_dsql_fetch(H->isc_status, &S->stmt, PDO_FB_SQLDA_VERSION, &S->out_sqlda)) { in firebird_stmt_fetch()
224 S->exhausted = 1; in firebird_stmt_fetch()
237 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_describe() local
239 XSQLVAR *var = &S->out_sqlda.sqlvar[colno]; in firebird_stmt_describe()
246 colname_len = (S->H->fetch_table_names && var->relname_length) in firebird_stmt_describe()
267 pdo_firebird_stmt *S = (pdo_firebird_stmt *) stmt->driver_data; in firebird_stmt_get_column_meta() local
268 XSQLVAR *var = &S->out_sqlda.sqlvar[colno]; in firebird_stmt_get_column_meta()
301 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_fetch_blob() local
302 pdo_firebird_db_handle *H = S->H; in firebird_fetch_blob()
387 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_get_col() local
388 XSQLVAR const *var = &S->out_sqlda.sqlvar[colno]; in firebird_stmt_get_col()
480 fmt = S->H->date_format ? S->H->date_format : PDO_FB_DEF_DATE_FMT; in firebird_stmt_get_col()
484 fmt = S->H->time_format ? S->H->time_format : PDO_FB_DEF_TIME_FMT; in firebird_stmt_get_col()
491 fmt = S->H->timestamp_format ? S->H->timestamp_format : PDO_FB_DEF_TIMESTAMP_FMT; in firebird_stmt_get_col()
510 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_bind_blob() local
511 pdo_firebird_db_handle *H = S->H; in firebird_bind_blob()
553 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_param_hook() local
554 XSQLDA *sqlda = param->is_param ? S->in_sqlda : &S->out_sqlda; in firebird_stmt_param_hook()
563 S->H->last_app_error = "Invalid parameter index"; in firebird_stmt_param_hook()
570 if ((index = zend_hash_find(S->named_params, param->name)) != NULL) { in firebird_stmt_param_hook()
589 S->H->last_app_error = "Invalid parameter name"; in firebird_stmt_param_hook()
640 S->H->last_app_error = "Cannot bind to array field"; in firebird_stmt_param_hook()
648 S->H->last_app_error = "Parameter requires non-null value"; in firebird_stmt_param_hook()
697 S->H->last_app_error = "Cannot convert string to boolean"; in firebird_stmt_param_hook()
709 S->H->last_app_error = "Binding arrays/objects is not supported"; in firebird_stmt_param_hook()
760 S->H->last_app_error = "Parameter requires non-null value"; in firebird_stmt_param_hook()
767 S->H->last_app_error = "Binding arrays/objects is not supported"; in firebird_stmt_param_hook()
796 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_set_attribute() local
806 if (isc_dsql_set_cursor_name(S->H->isc_status, &S->stmt, Z_STRVAL_P(val),0)) { in firebird_stmt_set_attribute()
810 strlcpy(S->name, Z_STRVAL_P(val), sizeof(S->name)); in firebird_stmt_set_attribute()
819 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_get_attribute() local
825 if (*S->name) { in firebird_stmt_get_attribute()
826 ZVAL_STRING(val, S->name); in firebird_stmt_get_attribute()
838 pdo_firebird_stmt *S = (pdo_firebird_stmt*)stmt->driver_data; in firebird_stmt_cursor_closer() local
841 …if ((*S->name || S->cursor_open) && isc_dsql_free_statement(S->H->isc_status, &S->stmt, DSQL_close… in firebird_stmt_cursor_closer()
845 *S->name = 0; in firebird_stmt_cursor_closer()
846 S->cursor_open = 0; in firebird_stmt_cursor_closer()