#46565 [Asn->WFx]: oci_fetch_all() returns ORA-01002
| From: | sixd@php.net | Date: | Wed, 06 Jan 2010 19:39:51 +0000 |
| Subject: | #46565 [Asn->WFx]: oci_fetch_all() returns ORA-01002 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-146392@lists.php.net to get a copy of this message | ||
ID: 46565
Updated by: sixd@php.net
Reported By: james_blond at hipernet dot brda dot net
-Status: Assigned
+Status: Wont fix
Bug Type: OCI8 related
Operating System: *
PHP Version: 5.2.6
Assigned To: sixd
New Comment:
I'm closing this because there are no plans to break existing
oci_fetch_all() behaviour.
Previous Comments:
------------------------------------------------------------------------
[2009-02-11 20:19:32] sixd@php.net
Until array functionality is introduced, make sure that
oci8.default_prefetch is set high in such cases.
------------------------------------------------------------------------
[2008-11-20 02:16:52] sixd@php.net
The use case was for a report generator, typically handling 10K rows,
and sometimes up to 80K. Batching would improve performance.
------------------------------------------------------------------------
[2008-11-19 00:18:49] sixd@php.net
The oci_fetch_all() function was designed to cancel a query after
being called once. The behavior you see is expected.
However it sounds like a possible enhancement.
------------------------------------------------------------------------
[2008-11-13 13:00:26] james_blond at hipernet dot brda dot net
Description:
------------
function oci_fetch_all on second use return error ORA-01002: fetch out
of sequence.
Reproduce code:
---------------
$dbstr = "(DESCRIPTION = (ADDRESS = PROTOCOL = TCP (HOST = host)(PORT =
1521))(CONNECT_DATA = (SID = sid)))";
$c = oci_connect("user","pass",$dbstr,"UTF8");
$SQL = "SELECT * FROM table "; // table have more then 100 rec
$s = oci_parse($c,$SQL);
oci_execute($s,OCI_COMMIT_ON_SUCCESS);
oci_fetch_all($s,$Row,0,10, OCI_NUM);
print_r($Row);
oci_fetch_all($s,$Row,10,10, OCI_NUM);// here return error ORA-01002
print_r($Row);
Expected result:
----------------
printed array $Row
Actual result:
--------------
array $Row is printed only on first time
on second $Row is empty , oci_fetch_all -> return error ORA-01002:
fetch out of sequence.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=46565&edit=1