The joy of support…

You may remember I wrote a blog post about the Enhanced Commit functionality of 10g Release 2 on the 4th of October in which I raised a question about the default action of BATCH/IMMEDIATE when not specified. On the 5th I raised a TAR in an attempt to answer the question, but still no luck. I came in this morning to find a bunch of waffle about commit processing had been added to the TAR and it had been closed. Had they answered my question? NO!

The phrase, “20% of the list price”, keeps ringing through my head! Where does this money go? Certainly not on paying people to read your question!

Oracle support is totally and utterly abysmal! Oracle need to do something about it, and it needs to be done quickly!

Don’t even get me started on support for the app servers or OCS…

You may have guessed I’m not a happy bunny!

Tim…

Update:

Almost as soon as I finished submitting this post I my TAR was switched to a member of the “Advanced Resolution Team”. Within a couple of hours he came back with the answer. The COMMIT_WRITE documentation is wrong and a bug (4668213) has been raised against it.

So, if neither IMMEDIATE or BATCH are specified, the default action is IMMEDIATE, whether you use the COMMIT WRITE command or the COMMIT_WRITE parameter.

A metalink note (336219.1) is due to be released soon with the correct information.

Pitty I didn’t get this guy first time round 🙂

I’ve updated my article and the related blog posts.

Google Reader

I’m experimenting with Google Reader as a replacement for BlogLines.

So far it doesn’t look too promising. I’ve had a bit of trouble with the subscription management. It occasionally fails, then works fine?? Also, the interface is a bit…. crappy. In this case the label “beta” is definitely appropriate. Some bits of the interface look badly formatted. I thought this was a firefox issue, but it’s the same on IE also.

What I do like it the idea of it presenting a reading list, rather than a list of blogs, some with new posts. In this respect it’s a little more like a news feed, rather than a list of blogs.

I’ll give it a go for a couple of days then make my decision. Google usually hit the mark so I can only assume this is the start of something better.

Cheers

Tim…

Question on enhanced commit processing in Oracle 10g Release 2…

I’ve been looking at the enhanced commit processing in Oracle 10g Release 2:

Commit Enhancements in Oracle 10g Database Release 2

In writing this article I’ve noticed a discrepancy in the default values for the COMMIT WRITE command and the COMMIT_WRITE parameter.

The COMMIT documentation says:

“If you specify neither WAIT nor NOWAIT, then WAIT is the default. If you specify neither IMMEDIATE nor BATCH, then IMMEDIATE is the default.”

In contrast the COMMIT_WRITE documentation says:

“If only IMMEDIATE or BATCH is specified, but not WAIT or NOWAIT, then WAIT mode is assumed.
If only WAIT or NOWAIT is specified, but not IMMEDIATE or BATCH, then BATCH mode is assumed.”

Is this difference true, or a documentation error? I guess I’ll have to raise a TAR about this, but if anyone knows the answer already I’d be grateful if you could pass it on.

Cheers

Tim…

Update:

The COMMIT_WRITE documentation is incorrect and Oracle support are raising a bug (4668213) against it. When neither BATCH or IMMEDIATE are specified the default action is IMMEDIATE, the same as the COMMIT WRITE command. A metalink note (336219.1) is due to be released soon with the correct information.

No shortcuts for SQL tuning…

From time to time I get questions like,

“How can I make this SQL statement run faster?”

When I see these questions I’m filled with dread. I don’t want to say nothing, but at the same time there is often little I can do to help because SQL tuning requires some knowledge of what you’re trying to achieve. So this post will serve as my generic answer.

Identify poorly performing SQL statements using Statspack, AWR or ADDM.

Once you’ve identified a problem SQL statement, trace it using SQL Trace to get hold of the execution plan and wait states, which should give you some idea of why it is performing so badly. Use this information to help you decide if you should do one or more of the following:

  • Rewrite the SQL statement.
  • Add suitable indexes to the underlying tables.
  • Force appropriate index usage with optimizer hints. Remember, forcing full scans by avoiding indexes may be appropriate in some situations (suggested by Jeff).
  • Check the statistics used by the optimizer are up to date. Gathering histograms may help. (suggested by Don and Nuno)

During the rewrite process Explain Plan and DBMS_XPLAN will provide you with the adjusted execution plan, without having to rerun the statement.

If you’re using Oracle 10g you might want to consider using the SQL Tuning Advisor or the SQL Access Advisor. I’ve seen limited success with these, but you may find them more useful.

At some point you may realize that no amount of tweaking is going to solve your performance problems and a more radical approach is necessary. In these cases it may be necessary to use materialized views to “pre-fetch” the data for your problem query, or just redesign that section of your application to make it more efficient.

If there are any shortcuts in this process please pass them on, because I’ve not found them yet 🙂

Cheers

Tim…

PS. I’ve made a couple of modifications based on comments 🙂