Lines Matching refs:sqldata

32 #define READ_AND_RETURN_USING_MEMCPY(type, sqldata) do { \  argument
34 memcpy(&ret, sqldata, sizeof(ret)); \
38 static zend_always_inline ISC_INT64 php_get_isc_int64_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_int64_from_sqldata() argument
40 READ_AND_RETURN_USING_MEMCPY(ISC_INT64, sqldata); in php_get_isc_int64_from_sqldata()
43 static zend_always_inline ISC_LONG php_get_isc_long_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_long_from_sqldata() argument
45 READ_AND_RETURN_USING_MEMCPY(ISC_LONG, sqldata); in php_get_isc_long_from_sqldata()
48 static zend_always_inline double php_get_double_from_sqldata(const ISC_SCHAR *sqldata) in php_get_double_from_sqldata() argument
50 READ_AND_RETURN_USING_MEMCPY(double, sqldata); in php_get_double_from_sqldata()
53 static zend_always_inline float php_get_float_from_sqldata(const ISC_SCHAR *sqldata) in php_get_float_from_sqldata() argument
55 READ_AND_RETURN_USING_MEMCPY(float, sqldata); in php_get_float_from_sqldata()
58 static zend_always_inline ISC_TIMESTAMP php_get_isc_timestamp_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_timestamp_from_sqldata() argument
60 READ_AND_RETURN_USING_MEMCPY(ISC_TIMESTAMP, sqldata); in php_get_isc_timestamp_from_sqldata()
63 static zend_always_inline ISC_QUAD php_get_isc_quad_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_quad_from_sqldata() argument
65 READ_AND_RETURN_USING_MEMCPY(ISC_QUAD, sqldata); in php_get_isc_quad_from_sqldata()
70 static zend_always_inline ISC_TIME_TZ php_get_isc_time_tz_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_time_tz_from_sqldata() argument
72 READ_AND_RETURN_USING_MEMCPY(ISC_TIME_TZ, sqldata); in php_get_isc_time_tz_from_sqldata()
75 …zend_always_inline ISC_TIMESTAMP_TZ php_get_isc_timestamp_tz_from_sqldata(const ISC_SCHAR *sqldata) in php_get_isc_timestamp_tz_from_sqldata() argument
77 READ_AND_RETURN_USING_MEMCPY(ISC_TIMESTAMP_TZ, sqldata); in php_get_isc_timestamp_tz_from_sqldata()
208 var->sqldata = &((char*)var->sqlind)[sizeof(short)]; in pdo_firebird_stmt_execute()
486 n = *(short*)var->sqldata; in pdo_firebird_stmt_get_col()
489 n = php_get_isc_long_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
492 n = php_get_isc_int64_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
500 str = zend_strpprintf(0, "%.*F", -var->sqlscale, php_get_double_from_sqldata(var->sqldata)); in pdo_firebird_stmt_get_col()
517 ZVAL_STRINGL_FAST(result, &var->sqldata[2], *(short*)var->sqldata); in pdo_firebird_stmt_get_col()
520 ZVAL_STRINGL_FAST(result, var->sqldata, var->sqllen); in pdo_firebird_stmt_get_col()
523 ZVAL_LONG(result, *(short*)var->sqldata); in pdo_firebird_stmt_get_col()
526 ZVAL_LONG(result, php_get_isc_long_from_sqldata(var->sqldata)); in pdo_firebird_stmt_get_col()
530 ZVAL_LONG(result, php_get_isc_int64_from_sqldata(var->sqldata)); in pdo_firebird_stmt_get_col()
532 …VAL_STR(result, zend_strpprintf(0, "%" LL_MASK "d", php_get_isc_int64_from_sqldata(var->sqldata))); in pdo_firebird_stmt_get_col()
537 … ZVAL_STR(result, zend_strpprintf_unchecked(0, "%.8H", php_get_float_from_sqldata(var->sqldata))); in pdo_firebird_stmt_get_col()
541 …ZVAL_STR(result, zend_strpprintf_unchecked(0, "%.16H", php_get_double_from_sqldata(var->sqldata))); in pdo_firebird_stmt_get_col()
544 ZVAL_BOOL(result, *(FB_BOOLEAN*)var->sqldata); in pdo_firebird_stmt_get_col()
547 isc_decode_sql_date((ISC_DATE*)var->sqldata, &t); in pdo_firebird_stmt_get_col()
551 isc_decode_sql_time((ISC_TIME*)var->sqldata, &t); in pdo_firebird_stmt_get_col()
556 ISC_TIMESTAMP timestamp = php_get_isc_timestamp_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
568 ISC_TIME_TZ time = php_get_isc_time_tz_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
572 ISC_TIMESTAMP_TZ ts = php_get_isc_timestamp_tz_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
577 ISC_QUAD quad = php_get_isc_quad_from_sqldata(var->sqldata); in pdo_firebird_stmt_get_col()
685 var->sqldata = &((char*)var->sqlind)[sizeof(short)]; in pdo_firebird_stmt_param_hook()
734 ISC_QUAD quad = php_get_isc_quad_from_sqldata(var->sqldata); in pdo_firebird_stmt_param_hook()
736 memcpy(var->sqldata, &quad, sizeof(quad)); in pdo_firebird_stmt_param_hook()
750 *(FB_BOOLEAN*)var->sqldata = zend_is_true(parameter) ? FB_TRUE : FB_FALSE; in pdo_firebird_stmt_param_hook()
758 *(FB_BOOLEAN*)var->sqldata = FB_FALSE; in pdo_firebird_stmt_param_hook()
764 *(FB_BOOLEAN*)var->sqldata = (lval != 0) ? FB_TRUE : FB_FALSE; in pdo_firebird_stmt_param_hook()
767 *(FB_BOOLEAN*)var->sqldata = (dval != 0) ? FB_TRUE : FB_FALSE; in pdo_firebird_stmt_param_hook()
771 *(FB_BOOLEAN*)var->sqldata = FB_TRUE; in pdo_firebird_stmt_param_hook()
773 *(FB_BOOLEAN*)var->sqldata = FB_FALSE; in pdo_firebird_stmt_param_hook()
803 var->sqldata = (void*)&Z_LVAL_P(parameter); in pdo_firebird_stmt_param_hook()
809 var->sqldata = (void*)&Z_DVAL_P(parameter); in pdo_firebird_stmt_param_hook()
837 var->sqldata = Z_STRVAL_P(parameter); in pdo_firebird_stmt_param_hook()