mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
master renames phase 1
This commit is contained in:
parent
0cf2dbdf58
commit
c3e3c98ec6
486 changed files with 11459 additions and 11541 deletions
|
@ -233,7 +233,7 @@ stmt_retry:
|
|||
ZEND_ATOI(stmt->row_count, PQcmdTuples(S->result));
|
||||
H->pgoid = PQoidValue(S->result);
|
||||
} else {
|
||||
stmt->row_count = (php_int_t)PQntuples(S->result);
|
||||
stmt->row_count = (zend_long)PQntuples(S->result);
|
||||
}
|
||||
|
||||
return 1;
|
||||
|
@ -359,7 +359,7 @@ static int pgsql_stmt_param_hook(pdo_stmt_t *stmt, struct pdo_bound_param_data *
|
|||
//SEPARATE_ZVAL_IF_NOT_REF(¶m->parameter);
|
||||
convert_to_string_ex(parameter);
|
||||
S->param_values[param->paramno] = Z_STRVAL_P(parameter);
|
||||
S->param_lengths[param->paramno] = Z_STRSIZE_P(parameter);
|
||||
S->param_lengths[param->paramno] = Z_STRLEN_P(parameter);
|
||||
S->param_formats[param->paramno] = 0;
|
||||
}
|
||||
|
||||
|
@ -391,7 +391,7 @@ static int pgsql_stmt_param_hook(pdo_stmt_t *stmt, struct pdo_bound_param_data *
|
|||
}
|
||||
|
||||
static int pgsql_stmt_fetch(pdo_stmt_t *stmt,
|
||||
enum pdo_fetch_orientation ori, php_int_t offset TSRMLS_DC)
|
||||
enum pdo_fetch_orientation ori, zend_long offset TSRMLS_DC)
|
||||
{
|
||||
pdo_pgsql_stmt *S = (pdo_pgsql_stmt*)stmt->driver_data;
|
||||
|
||||
|
@ -480,7 +480,7 @@ static int pgsql_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC)
|
|||
break;
|
||||
|
||||
case INT8OID:
|
||||
if (sizeof(php_int_t)>=8) {
|
||||
if (sizeof(zend_long)>=8) {
|
||||
cols[colno].param_type = PDO_PARAM_INT;
|
||||
} else {
|
||||
cols[colno].param_type = PDO_PARAM_STR;
|
||||
|
@ -498,7 +498,7 @@ static int pgsql_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC)
|
|||
return 1;
|
||||
}
|
||||
|
||||
static int pgsql_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, php_uint_t *len, int *caller_frees TSRMLS_DC)
|
||||
static int pgsql_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, zend_ulong *len, int *caller_frees TSRMLS_DC)
|
||||
{
|
||||
pdo_pgsql_stmt *S = (pdo_pgsql_stmt*)stmt->driver_data;
|
||||
struct pdo_column_data *cols = stmt->columns;
|
||||
|
@ -521,7 +521,7 @@ static int pgsql_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, php_uint_
|
|||
case PDO_PARAM_INT:
|
||||
ZEND_ATOI(S->cols[colno].intval, *ptr);
|
||||
*ptr = (char *) &(S->cols[colno].intval);
|
||||
*len = sizeof(php_int_t);
|
||||
*len = sizeof(zend_long);
|
||||
break;
|
||||
|
||||
case PDO_PARAM_BOOL:
|
||||
|
@ -577,7 +577,7 @@ static int pgsql_stmt_get_col(pdo_stmt_t *stmt, int colno, char **ptr, php_uint_
|
|||
return 1;
|
||||
}
|
||||
|
||||
static int pgsql_stmt_get_column_meta(pdo_stmt_t *stmt, php_int_t colno, zval *return_value TSRMLS_DC)
|
||||
static int pgsql_stmt_get_column_meta(pdo_stmt_t *stmt, zend_long colno, zval *return_value TSRMLS_DC)
|
||||
{
|
||||
pdo_pgsql_stmt *S = (pdo_pgsql_stmt*)stmt->driver_data;
|
||||
PGresult *res;
|
||||
|
@ -593,7 +593,7 @@ static int pgsql_stmt_get_column_meta(pdo_stmt_t *stmt, php_int_t colno, zval *r
|
|||
}
|
||||
|
||||
array_init(return_value);
|
||||
add_assoc_int(return_value, "pgsql:oid", S->cols[colno].pgsql_type);
|
||||
add_assoc_long(return_value, "pgsql:oid", S->cols[colno].pgsql_type);
|
||||
|
||||
/* Fetch metadata from Postgres system catalogue */
|
||||
spprintf(&q, 0, "SELECT TYPNAME FROM PG_TYPE WHERE OID=%u", S->cols[colno].pgsql_type);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue