diff options
author | Antony Dovgal <tony2001@php.net> | 2006-03-18 22:06:31 +0000 |
---|---|---|
committer | Antony Dovgal <tony2001@php.net> | 2006-03-18 22:06:31 +0000 |
commit | 4e75cd55486cfba77bec9392424fcd9341e049e5 (patch) | |
tree | f2444f0fbd723058e8b935da904f40eb23a6ed3e | |
parent | fa922fb51cbada2a1fa9aec5dd542979f13a456b (diff) | |
download | php-git-4e75cd55486cfba77bec9392424fcd9341e049e5.tar.gz |
Added support for BINARY_DOUBLE and BINARY_FLOAT to PDO_OCI and OCI8 (also fixes bug #36764)
-rw-r--r-- | NEWS | 2 | ||||
-rw-r--r-- | ext/oci8/oci8_statement.c | 4 | ||||
-rwxr-xr-x | ext/pdo_oci/oci_statement.c | 4 |
3 files changed, 10 insertions, 0 deletions
@@ -5,6 +5,8 @@ PHP NEWS - Eliminated run-time constant fetching for TRUE, FALSE and NULL. (Dmitry) - Fixed offset/length parameter validation in substr_compare() function. (Ilia) - Added overflow checks to wordwrap() function. (Ilia) +- Added support for BINARY_DOUBLE and BINARY_FLOAT to PDO_OCI and OCI8 + (also fixes bug #36764). (Tony) - Removed the E_STRICT deprecation notice from "var". (Ilia) - Fixed debug_zval_dump() to support private and protected members. (Dmitry) - Fixed bug #36756 (DOMDocument::removeChild corrupts node). (Rob) diff --git a/ext/oci8/oci8_statement.c b/ext/oci8/oci8_statement.c index c0e865bd16..f930fdaa77 100644 --- a/ext/oci8/oci8_statement.c +++ b/ext/oci8/oci8_statement.c @@ -502,6 +502,10 @@ int php_oci_statement_execute(php_oci_statement *statement, ub4 mode TSRMLS_DC) #endif ) { outcol->storage_size4 = 512; /* XXX this should fit "most" NLS date-formats and Numbers */ +#if defined(SQLT_IBFLOAT) && defined(SQLT_IBDOUBLE) + } else if (outcol->data_type == SQLT_IBFLOAT || outcol->data_type == SQLT_IBDOUBLE) { + outcol->storage_size4 = 1024; +#endif } else { outcol->storage_size4++; /* add one for string terminator */ } diff --git a/ext/pdo_oci/oci_statement.c b/ext/pdo_oci/oci_statement.c index 46a8cea720..96723a05cf 100755 --- a/ext/pdo_oci/oci_statement.c +++ b/ext/pdo_oci/oci_statement.c @@ -545,6 +545,10 @@ static int oci_stmt_describe(pdo_stmt_t *stmt, int colno TSRMLS_DC) /* {{{ */ ) { /* should be big enough for most date formats and numbers */ S->cols[colno].datalen = 512; +#if defined(SQLT_IBFLOAT) && defined(SQLT_IBDOUBLE) + } else if (dtype == SQLT_IBFLOAT || dtype == SQLT_IBDOUBLE) { + S->cols[colno].datalen = 1024; +#endif } else { S->cols[colno].datalen = col->maxlen; } |