Optimizer Compatibility, Short Pants and Hot Sauce

OK, so I’m all over the map, (technology wise) right now.  One day I’m working with data masking on Oracle, the next it’s SQL Server or MySQL, and the next its DB2.  After almost six months of this, the chaos of feeling like a fast food drive thru with 20 lanes open at all times is starting to make sense and my brain is starting to find efficient (more...)

Distributed Trap

Here’s an interesting (and potentially very useful) observation from an OTN database forum thread that appeared at the end of last week. It concerns the problems of pulling data from remote systems, and I’ll start by building some data:

rem     Script:         remote_insert_2.sql
rem     Author:         Jonathan Lewis
rem     Dated:          Nov 2016
rem     Last tested

create table t1
with generator as (

Yes, Storage Arrays Can Deduplicate Oracle Database. Here Is Exactly Why It Doesn’t Matter!

I recently had some cycles on a freshly installed Dell EMC XtremIO Storage Array. I took this opportunity to prepare a blog entry about the never-ending topic of whether or not storage arrays are able to reduce physical data capacity through deduplication of blocks in Oracle Database.

Of Course There Is Duplicate Data In Oracle Datafiles

Before I continue, let me say something that may come as a surprise to you. Yes, Oracle Database has (more...)

Oracle 12cR2: Database parameters

For those in a desperate need to learn all 4841 database parameter variations of the…

Oracle DBaaS database available

Just created by first Extreme Performance database in the cloud.oracle.com. So just after a…

Oracle Manuals available now!

Have a look what’s new and cool in the full Oracle manuals / documentation…

Enqueue Bytes – Is that a Pun?

Sometimes it is necessary to put on your uber-geek hat and start using cryptic bits of code to retrieve information from an Oracle database. Troubleshooting enqueue locking events in Oracle databases is one of the times some advanced SQL may be necessary.

Likely you have used SQL similar to the following when troubleshooting Oracle enqueue’s, probably in connection with row lock contention.

SQL# l
  2     s.username username,
  3     s.sid (more...)


A current question on the OTN database forum asks: “What’s the difference between object and tablespace reorganization?” Here’s an analogy to address the question.

I have three crates of Guiness in the boot (trunk) of my car, one crate has 4 bottles left, one has 7 bottles left and one has 2 bottles. I also have two cases of Louis Roederer Brut NV champagne, one case has 2 bottles left and one has only (more...)

Filter Subquery

There’s a current thread on the OTN database forum showing an execution plan with a slightly unusual feature. It looks like this:

| Id  | Operation                                |  Name                          | Rows  | Bytes |TempSpc| Cost  | Pstart| Pstop |  
|   0 | SELECT STATEMENT                         |                                |   137K|    27M|       |   134K|       |       |  
|*  1 |  HASH JOIN                               |                                |   137K|    27M|    27M|   134K|       |       |  
|*  2 |   HASH JOIN                              |                                |   140K|    26M|   (more...)

Default Tablespace Encryption In The Clouds?

One of my customers called me up last week and said he’s been having the most peculiar problem. He created a new instance on the Microsoft Azure environment ( and he can’t create new tablespace. The error he’s getting “ORA-28365: wallet is not open” and he was wondering “what gives?!”.

This is kind of an interesting issue. When someone who never heard of the wallet, looking at the message doesn’t mean anything reasonable. (more...)

srvctl start/stop/status home

Learning new things by actually reading the log files.

$ srvctl status home -o /u01/app/oracle/product/ -s ~/statushome.txt -n rac01; cat ~/statushome.txt
Service emu_svc is running on node rac01
Database emu is running on node rac01

$ srvctl stop home -o /u01/app/oracle/product/ -s ~/stophome.txt -n rac01 -t immediate -f
PRKO-3244 : The -s  option value "/home/oracle/stophome.txt" already exists

$ rm -f  (more...)

Using opatch report feature

I have been patching a lot lately and started to wonder if this is a simpler way to check for patch conflict.

Reviewing the log from running opatch auto shows opatch auto does perform check; hence, why do we need to check this manually?

What about creating scripts to do this? Done this as well and will required modifications when requirements are changed.

If the post name did not give it away or if you (more...)

tnsnames.ora, keeping your connections under control

There are a lot of ancient things that prove to be still valuable today.
Recently I came across something, which I thought I could or should share here.
Your tnsnames.ora file, centrally managed in a distributed environment.

This solution applies whether you are working with the Oracle Instant Client or with the full blown setup of the client software.

Imagine you have an environment with a reasonably big bunch of PC’s. Wether you are (more...)

Distinguish Real SQL Execution Plans from Fake Ones!

Distinguish Real Execution Plans from Fake Ones!

As an Oracle DBA, one of our daily tasks is to optimize bad SQL statements that are affecting the system and causing performance degradation. First we identify the culprit SQL, then we extract the execution plan, after that, we start the cycle of SQL tuning and optimization as appropriate.


There are many methods to extract the execution plan for a specific SQL statement, however, not all these (more...)

Scoop – First glance of new Oracle Live SQL?

When I was at OOW this year I saw the new (?) Oracle Live SQL…

Oracle Database Cloud Service: Set up Access Rules

I’ve started to test Oracle Database Cloud Services. I applied for trial, it’s accepted (you can also get a trial account, there’s no special requirement for it). After I got my welcome emails, I created a database service. As expected, it was very easy. All I needed is to click a couple of times, enter mandatory information and then wait until my Database is provisioned.

Oracle creates a VM for each database because they provide (more...)

I am now an ex-ACE Director

How apt that this should be my next blog post, following So long, and thanks for all the fish. I’ve been an Oracle ACE Director since 2009, and watched the program evolve in form considerably over that time. It’s always difficult to maintain high quality advocacy as a program grows – my time as part of the OakTable ‘junta’ … Continue reading "I am now an ex-ACE Director"

New Index enhancement in Oracle 12c Part 1 – Multiple indexes on the same set of columns

New Index enhancement in Oracle 12c Part 1 – Multiple indexes on the same set of columns


In the article you will have a look at the following new index feature in oracle 12c ‘Multiple indexes on the same set of columns’. Staring with Oracle 12c you are enabled to create multiple indexes on the same set of columns. The following different indexes can be created on the same set of columns.

  1. Index of (more...)

Installing OEM13c management agent in silent mode

For many customers I work with SSH won’t be available between the OEM and monitoring hosts. Therefore you cannot push the management agent on to the host from the OEM console. Customer might have to raise CR to allow SSH between the hosts but this might take a while and it’s really unnecessary.

In that case the management agent has to be installed in silent mode. That is when the agent won’t be pushed from (more...)

What keeps database administrators awake at night and the search for the promised land

What keeps you and me awake at night? When I was a consultant for a Fortune 500 company in Southern California, we were getting beaten up to prove that databases were being backed up correctly and that disaster recovery would work. The truth of the matter was that we didn’t even have an accurate list of all the databases and databases would go down for days without anybody noticing which means that they were not (more...)