News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Christopher Jones' Blog:
When a few seconds are important improving PHP Oracle connection speed
March 28, 2007 @ 08:33:00

In a new post to his Oracle blog today, Christopher Jones has a handy tip to help you speed up your Oracle-using PHP scripts by as much as few seconds. The tip originally comes from Krishna Mohan.

What Krishna pointed out was that specifying the client character set name as the optional fourth parameter to oci_pconnect() has a postive effect on performance. If you let the value default then PHP has to invoke code to determine what the client character set should be. This lookup may involve a potentially expensive environment check.

So, a speed increase might be as easy as adding another parameter to your scripts. Christopher includes an example to show where the value goes (in an oci_pconnect call).

Testing with the database and PHP both on my little old machine I was getting figures like 0.6 vs 2.7 seconds for 50,000 pconnect calls in the one script. I saw some other results that showed only a three-times difference.
0 comments voice your opinion now!
oracle connection speed characterset parameter ocipconnect oracle connection speed characterset parameter ocipconnect


blog comments powered by Disqus

Similar Posts

Lukas Smith's Blog: Persistent connections with MSSQL

Fabien Potencier's Blog: Symfony Service Container: The Need for Speed

Christopher Jones' Blog: Customer Interview on PHP & Oracle 11g Connection Pooling (DRCP) in Oracle

Zend Developer Zone: The ZendCon Sessions Ep 14: Performance Tuning for PHP with Oracle Database

Ajax Developer\'s Jorunal: Zend Announces Update Of Zend Core For Oracle


Community Events

Don't see your event here?
Let us know!


api example php7 library language release unittest introduction opinion extension xdebug interview install laravel podcast voicesoftheelephpant series community laravel5 framework

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework