-

JDBC, the FetchSize and staying up to date
When you are querying rows from an Oracle Database, a key element of the Oracle JDBC driver related to performance is an attribute known as the fetch size. For those unfamiliar with the fetch size, when you issue a FETCH for a single row from our JDBC driver, we will go grab a batch of Read more
-

DataPump – niche fix
On a Office Hours session a while back, someone brought up this niche issue when use DataPump and you have “overlapping” indexes. What do I mean by “overlapping indexes”? Consider the following example. Notice that I have two indexes (one implicitly create as part of the constraint definition, and one explicitly created with CREATE INDEX) Read more
-

OPatch – The “File In Use” error that wasn’t
Over the holiday break I took the opportunity to apply the latest RU to some of my databases. On my 21c Windows instance, as I was running “opatch apply” I got the following error: X:\tmp\36878842>opatch apply Oracle Interim Patch Installer version 12.2.0.1.44 Copyright (c) 2025, Oracle Corporation. All rights reserved. Oracle Home : c:\oracle\product\21 Central Read more
-

The year in numbers
The numbers might be one or two off, because I’m not the kind of person who really sweats hard over the numbers. I’m much more interested in what content you find most beneficial for your own success, so if you have any particular requests for 2025, I’m always happy to take your comments on board. Read more
-

Christmas Puzzle – The Solution
A huge “Well done!” to all those people that made the realisation that we had to be storing the data in a datatype that can manipulate the data internally as it is stored. Thus datatypes like JSON and XMLTYPE became the obvious candidates. No-one matched exactly the way I constructed the problem, but for those Read more
-

Kris Kringle the Database – The Christmas MYSTERY
Here’s a strange but true puzzle for you. See if you can work out the solution… Riddle me this – I created a brand new schema, and in that schema I created a single table called T with a single column called DATA. With some simple PL/SQL I inserted a 40byte string into that table Read more
-

Kris Kringle the Database – All gather ROUND
Ever thought something should be pretty simple, but turns out it isn’t? A perfect example of this is the topic of todays post… Rounding! A quick look at the Wiki for Rounding discusses (I kid you not) THIRTEEN 🤣 methods of rounding, and that doesn’t include some of the other sub-topics on rounding with different Read more
-

Kris Kringle the Database – What a Great GROUP
Often what starts off as a simple aggregation… SQL> select channel_id, promo_id, sum(amount_sold) tot 2 from sh.sales 3 group by channel_id, promo_id 4 order by 1,2; CHANNEL_ID PROMO_ID TOT ———- ———- ———- 2 350 548779.15 2 999 25797563.2 3 350 1329476.49 3 351 1208839.02 3 999 55336945.1 4 350 321125.26 4 351 15664.24 4 999 Read more
-

Kris Kringle the Database! What DAY is it?
This one catches me out more often than I’d like to admit. It all starts off easy – I take a look at what day of the week it is. SQL> select to_char(sysdate,’DAY’) from dual; TO_CHAR(SYSDATE,’DAY’) ———————————— WEDNESDAY No problem. Now I’ll build some code logic around that query in order to run certain tasks Read more
-

Kris Kringle the Database – Friday RANT
Ever seen code like this? select * from EMP where 1=1 and sal > 10 and dept_no = 20 You would probably wonder: Why is there a “WHERE 1=1” predicate? Surely that does nothing? And you would be absolutely right…IT DOES NOTHING. I should clarify – it does nothing, if you were referring to the Read more
-

Kris Kringle the Database – Taking the LEAP
What is a quick way of working out if a year happens to be a leap year? Here’s my first attempt SQL> create or replace 2 function f1(y number) return boolean is 3 x date; 4 begin 5 x := to_date(‘2902’||y,’ddmmyyyy’); 6 return true; 7 exception 8 when others then return false; 9 end; 10 Read more
-

Kris Kringle the Database – No Fault in DEFAULT
A lot of people are unaware that when you have a column with a DEFAULT attached to it, you do not need to go hunting around in the data dictionary to get access to it. For example, let me start with this simple people table where the default for ACTIVE is “YES” SQL> create table Read more