Lines Matching refs:param

411 static int firebird_bind_blob(pdo_stmt_t *stmt, ISC_QUAD *blob_id, zval *param TSRMLS_DC)  in firebird_bind_blob()
425 SEPARATE_ZVAL(&param); in firebird_bind_blob()
427 convert_to_string_ex(&param); in firebird_bind_blob()
429 for (rem_cnt = Z_STRLEN_P(param); rem_cnt > 0; rem_cnt -= chunk_size) { in firebird_bind_blob()
433 if (isc_put_segment(H->isc_status, &h, chunk_size, &Z_STRVAL_P(param)[put_cnt])) { in firebird_bind_blob()
441 zval_dtor(param); in firebird_bind_blob()
450 static int firebird_stmt_param_hook(pdo_stmt_t *stmt, struct pdo_bound_param_data *param, /* {{{ */ in firebird_stmt_param_hook() argument
454 XSQLDA *sqlda = param->is_param ? S->in_sqlda : &S->out_sqlda; in firebird_stmt_param_hook()
461 if (!sqlda || param->paramno >= sqlda->sqld) { in firebird_stmt_param_hook()
466 if (param->is_param && param->paramno == -1) { in firebird_stmt_param_hook()
470 if (SUCCESS == zend_hash_find(S->named_params, param->name, param->namelen+1, (void*)&index)) { in firebird_stmt_param_hook()
471 param->paramno = *index; in firebird_stmt_param_hook()
479 if ((var->aliasname_length && !strncasecmp(param->name, var->aliasname, in firebird_stmt_param_hook()
480 min(param->namelen, var->aliasname_length))) in firebird_stmt_param_hook()
481 || (var->sqlname_length && !strncasecmp(param->name, var->sqlname, in firebird_stmt_param_hook()
482 min(param->namelen, var->sqlname_length)))) { in firebird_stmt_param_hook()
483 param->paramno = i; in firebird_stmt_param_hook()
495 var = &sqlda->sqlvar[param->paramno]; in firebird_stmt_param_hook()
503 if (param->is_param) { in firebird_stmt_param_hook()
514 if (!param->is_param) { in firebird_stmt_param_hook()
528 param->parameter TSRMLS_CC); in firebird_stmt_param_hook()
532 switch (Z_TYPE_P(param->parameter)) { in firebird_stmt_param_hook()
538 var->sqldata = (void*)&Z_LVAL_P(param->parameter); in firebird_stmt_param_hook()
544 var->sqldata = (void*)&Z_DVAL_P(param->parameter); in firebird_stmt_param_hook()
560 force_null = (Z_STRLEN_P(param->parameter) == 0); in firebird_stmt_param_hook()
565 var->sqldata = Z_STRVAL_P(param->parameter); in firebird_stmt_param_hook()
566 var->sqllen = Z_STRLEN_P(param->parameter); in firebird_stmt_param_hook()
586 if (param->paramno == -1) { in firebird_stmt_param_hook()
589 if (param->is_param) { in firebird_stmt_param_hook()
596 if (firebird_stmt_get_col(stmt, param->paramno, &value, &value_len, &caller_frees TSRMLS_CC)) { in firebird_stmt_param_hook()
597 switch (PDO_PARAM_TYPE(param->param_type)) { in firebird_stmt_param_hook()
600 ZVAL_STRINGL(param->parameter, value, value_len, 1); in firebird_stmt_param_hook()
605 ZVAL_LONG(param->parameter, *(long*)value); in firebird_stmt_param_hook()
609 if (!param->is_param) { in firebird_stmt_param_hook()
610 char *s = param->name; in firebird_stmt_param_hook()
618 ZVAL_NULL(param->parameter); in firebird_stmt_param_hook()