Re: Slow statement when using JDBC - Mailing list pgsql-jdbc

From David G Johnston
Subject Re: Slow statement when using JDBC
Date
Msg-id 1405920728079-5812174.post@n5.nabble.com
Whole thread Raw
In response to Slow statement when using JDBC  (yazan suleiman <yazan.suleiman@gmail.com>)
Responses Re: Slow statement when using JDBC
List pgsql-jdbc
arunkmp wrote
> i tested same query in php using pear-Db connectivity its nomally 2 times
> faster than java conntivity.
>
> for both my postgresql version 9.1,
>
> can anyone explain me why its speeder in php.

Given that the reason for the poor JDBC performance has been explained this
likely isn't the best list to get answers as to why PHP doesn't seem to
exhibit the same problem...

It would probably also help to supply actual code since your use of the two
libraries could be a contributing factor.

And the versions of the drivers would also be good information to supply...

PHP is possibly bypassing the whole "prepare" aspect and simply providing
what appears to be a prepared statement interface while actually sending
complete queries, without parameters, to the database.  This would explain
the difference but is truly a guess since I have not used Pear/PHP.

David J.



--
View this message in context:
http://postgresql.1045698.n5.nabble.com/Slow-statement-when-using-JDBC-tp3368379p5812174.html
Sent from the PostgreSQL - jdbc mailing list archive at Nabble.com.


pgsql-jdbc by date:

Previous
From: Dave Cramer
Date:
Subject: Re:
Next
From: arunkmp
Date:
Subject: Re: Slow statement when using JDBC