Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> JDBC,soft and hard parses, hit ratios

JDBC,soft and hard parses, hit ratios

From: Doug Cowles <dcowles_at_i84.net>
Date: 2000/06/09
Message-ID: <oe03ks0rpv3jfh4c984vl8ijvgg11cufhp@4ax.com>#1/1

I noticed something alarming in my database last week. During a scalability test, I doubled the size of a batch job and ended up with a fragmented shared pool. Could of just made the pool bigger, but noticed that THOUSANDS of sql statements called with a JDBC thin driver were not using bind variables and were highly repetitive. Such as
delete from tablex where id = 5
delete from tablex where id = 6
...hundreds more
etc.,
Sent back a request to the developers that they rework things to use bind variables (which I got the impression was a little involved.. anyone care to comment on that?).. so that we could keep a nice and tidy shared pool.

But.. it got me thinking about parsing in general. If someone is not using a bind variable, it is a hard parse every time a statement rolls through, is that right?

If someone is using a bind variable, then it is a hard parse the first time the statemnet is parsed, and a soft parse each time thereafter as long as the statement remains in the pool.. is that right?

So.. what I was wondering, other than the other questions above, is whether a soft parse counts against by hit ratios (library cache.. ). I would think it doesn't, as I would imagine a statement using a bind variable would be a hit, or a pin hit, or would it not? I find it a little hard to swallow with so many tuned up databases reporting hit ratios of .99, .98 etc., that the statements are identical in form and data, so I'm guessing a soft parse with different variables inserted in them is a hit.. Am I right? Clearly..I'm not sure...

Thanks for any help,

Received on Fri Jun 09 2000 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US