Bug #46471 [Fbk->NoF]: Performance problem when reading XML columns

From: Date: Sun, 16 May 2021 04:22:13 +0000
Subject: Bug #46471 [Fbk->NoF]: Performance problem when reading XML columns
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-233845@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=46471&edit=1

 ID:               46471
 Updated by:       php-bugs@lists.php.net
 Reported by:      rgpublic at gmx dot net
 Summary:          Performance problem when reading XML columns
-Status:           Feedback
+Status:           No Feedback
 Type:             Bug
 Package:          OCI8 related
 Operating System: Linux
 PHP Version:      5.2SVN-2009-10-19 (snap)
 Assigned To:      cmb
 Private report:   N

 New Comment:

No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.


Previous Comments:
------------------------------------------------------------------------
[2021-05-03 12:53:46] cmb@php.net

Is this still an issue with any of the actively supported PHP
versions[1]?

[1] <https://www.php.net/supported-versions.php>

------------------------------------------------------------------------
[2009-10-20 17:44:49] rgpublic at gmx dot net

Thank you for your answer. Results vary depending on the performance
of the database server. As I have written I can generally say the
simple approach always takes about twice the time. I assume you mean
with "a lot more function calls" that oci_fetch_array is called in a
while-loop causing round-trips to the database-server. That is right
of course, but oci_set_prefetch should solve this at least
partically, and it does not seem to have any influence. And without
LOB columns oci_fetch_array is MUCH faster. The actual payload data
(i.e. without internal overhead) transferred between server and
client is obviously the same with both approaches. So that leaves us
with the following facts:
1) The reason for the slowness is not that reading the lobs is slow.
Otherwise the PL/SQL script wouldnt be able to get it faster
2) The reason is not that the network speed is limited. Otherwise
both aprroaches would have the same speed

IMO this leaves the whole chain down to the OCI module out of the
picture. So the reason for this slowness lies in the OCI module.
That's why I filed this bug. When you use Oracle's XML features to
store lots of XML documents in a large table and want to retrieve
many of them this slowness is causing a lot of problems. Simply
reading back the data exactly as you have stored it in the database
before shouldnt cause such a huge performance penalty IMHO.

------------------------------------------------------------------------
[2009-10-20 10:19:51] jani@php.net

Exactly what results do you get? And why do you really think it should be any faster, considering
you're doing a lot more function calls with the "simple" approach?

------------------------------------------------------------------------
[2009-10-19 21:12:49] rgpublic at gmx dot net

Still happens with recent snapshot.

------------------------------------------------------------------------
[2009-10-19 15:00:08] jani@php.net

Please try using this snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/



------------------------------------------------------------------------


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=46471


--
Edit this bug report at https://bugs.php.net/bug.php?id=46471&edit=1


Thread (9 messages)

« previous php.bugs (#233845) next »