diff --git a/ext/oci8/oci8.stub.php b/ext/oci8/oci8.stub.php index 8bbd294e923..519792f86ca 100644 --- a/ext/oci8/oci8.stub.php +++ b/ext/oci8/oci8.stub.php @@ -239,7 +239,7 @@ function ocifetchinto($statement, &$result, int $mode = OCI_NUM): int|false {} * @param resource $statement * @param array $output */ -function oci_fetch_all($statement, &$output, int $offset = 0, int $limit = -1, int $flags = 0): int {} +function oci_fetch_all($statement, &$output, int $offset = 0, int $limit = -1, int $flags = OCI_FETCHSTATEMENT_BY_COLUMN | OCI_ASSOC): int {} /** * @param resource $statement @@ -247,7 +247,7 @@ function oci_fetch_all($statement, &$output, int $offset = 0, int $limit = -1, i * @alias oci_fetch_all * @deprecated */ -function ocifetchstatement($statement, &$output, int $offset = 0, int $limit = -1, int $flags = 0): int {} +function ocifetchstatement($statement, &$output, int $offset = 0, int $limit = -1, int $flags = OCI_FETCHSTATEMENT_BY_COLUMN | OCI_ASSOC): int {} /** @param resource $statement */ function oci_fetch_object($statement, int $mode = OCI_ASSOC | OCI_RETURN_NULLS): stdClass|false {} diff --git a/ext/oci8/oci8_arginfo.h b/ext/oci8/oci8_arginfo.h index 8ccb118b499..6dc02395d98 100644 --- a/ext/oci8/oci8_arginfo.h +++ b/ext/oci8/oci8_arginfo.h @@ -1,5 +1,5 @@ /* This is a generated file, edit the .stub.php file instead. - * Stub hash: 4df305f0e3750245ed9f9f9bc10edc339328084a */ + * Stub hash: 95565a6dc86d41fa6ddf3228d68ac0c5167dbe37 */ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_oci_define_by_name, 0, 3, _IS_BOOL, 0) ZEND_ARG_INFO(0, statement) @@ -216,7 +216,7 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_oci_fetch_all, 0, 2, IS_LONG, 0) ZEND_ARG_INFO(1, output) ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, offset, IS_LONG, 0, "0") ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, limit, IS_LONG, 0, "-1") - ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flags, IS_LONG, 0, "0") + ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flags, IS_LONG, 0, "OCI_FETCHSTATEMENT_BY_COLUMN | OCI_ASSOC") ZEND_END_ARG_INFO() #define arginfo_ocifetchstatement arginfo_oci_fetch_all diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c index a111da9676c..98a6cdf0abb 100644 --- a/ext/oci8/oci8_interface.c +++ b/ext/oci8/oci8_interface.c @@ -1274,7 +1274,7 @@ PHP_FUNCTION(oci_fetch_all) zval **outarrs; ub4 nrows = 1; int i; - zend_long rows = 0, flags = 0, skip = 0, maxrows = -1; + zend_long rows = 0, flags = PHP_OCI_FETCHSTATEMENT_BY_COLUMN, skip = 0, maxrows = -1; ZEND_PARSE_PARAMETERS_START(2, 5) Z_PARAM_RESOURCE(z_statement)