Close

How big is a table?

I’ve been asked this question in various forms and forums over the years and the askers are often surprised when I tell them there is more than one way to answer that question. Furthermore, each method yields a different but not necessarily wrong answer! First, let’s take a simple, maybe even obvious method: SELECT avg_row_len…

Oracle 18c Documentation is now available on OTN!

https://docs.oracle.com/en/database/oracle/oracle-database/18/index.html Definitely interested in looking into the json functionality https://docs.oracle.com/en/database/oracle/oracle-database/18/adjsn/changes.html#GUID-8C9B00DD-45D8-499B-919C-8632E034B664 and digging in more with analytic views https://docs.oracle.com/en/database/oracle/oracle-database/18/sqlrf/Changes-in-This-Release-for-Oracle-Database-SQL-Language-Reference.html#GUID-9D1C204A-91C3-4B8D-A882-374F78118862

Using Object Types: constructors

When an object type is instantiated (i.e. assigned a non-null value) it will execute initialization code. This initialization code is called a CONSTRUCTOR function. Every object type includes an implicit constructor which simply assigns values to the object attributes according to the values provided in the object assignment. For example: CREATE OR REPLACE TYPE simpleobject…

Oracle ACE

Oracle gave me an unexpected present for Christmas this year by naming me an Oracle ACE! I’m truly honored to be included in the ranks of so many I’ve read and learned from. Of course I’m also extremely happy to know my efforts to return the favor and share my knowledge and experience has been…

PBKDF2 in Oracle 12c

When I wrote my article on Oracle passwords I included a small, limited implementation of the PBKDF2 algorithm in order to illustrate the 12c hashing methodology.    Here I’m publishing a fuller implementation with parameters for determining the derived key length, number of hashing iterations, and a choice of hashing methods (SH1, SH256, SH384, or SH512.) …

Missing peaks in ASH results

The ASH charts in OEM are great utilities for getting a quick summary of your system’s activity. However, these results can be misleading because of how the data is represented on screen. First, ASH is data is collected by sampling so it’s not a complete picture of everything that runs. Another thing to consider is…

The Curse of “Expertise”

Like everyone else, I make mistakes. While the results can sometimes be unfortunate, it’s also a truth that shouldn’t be ignored. A recurring problem though is that as a designated “expert” sometimes people don’t bother to test what I’ve given them. They just roll with it and then are surprised when their production installation goes…

Finding the name of an Oracle database

Oracle offers several methods for finding the name of a database. More significantly, 12c introduces new functionality which may change the expected value from some of the old methods due to the multi-tenant feature. Here are 11 methods for finding the name of a database. SELECT ‘ora_database_name’ method, ora_database_name VALUE FROM DUAL UNION ALL SELECT…

See you in Las Vegas!

I’m flying out tomorrow for Collaborate 16. Looking forward to another great conference. I’m presenting again this year. I’ll be speaking on Tuesday, at 2:15 “Why Developers Need to Think like DBAs, Why DBAs Need to Think like Developers” Session 1355 in Jasmine C

Splitting a clob into rows

I’ve used this tool for a wide variety of other parsing projects. One of the interesting tuning techniques I used was to pull the clob apart into 32K varchar2 chunks. It is possible to split the clob directly using the DBMS_LOB package or through the overloaded SQL functions; but clobs are expensive objects. Varchar2 variables…

Thank you, thank you, thank you!

A little while ago Oracle announced the winners of the Oracle Database Developer Choice Awards and I was a winner in both of categories I was nominated, SQL and PL/SQL I was surprised and overjoyed when I was notified that I had not only been nominated; but named a finalist. I’m truly humbled by the…

A day late but still fun

Yesterday Kim Berg Hansen posted a couple entries to his blog about scraping and parsing the Oracle Developer Choice Awards voting pages and building summaries of the results. I’ve been doing something similar since the voting began but took a slightly different approach. I do like the idea of storing them in a table to…

Update to LDAP package

I’m in the process of updating my OID package from last year to version 2.0. The new version will include a significant change in API but will also include more functionality, in particular, support for TNS aliases. I’m also changing the way exceptions are raised as well as improving the efficiency of searches. Along the…

Managing TNS lookups in OpenLDAP via PL/SQL

I have an Oracle Express Edition (XE) database running on almost every pc in my home. It’s not so numerous that I can’t manage them by manipulation of TNSNAMES.ORA; but I always thought it would be nice to manage them centrally via LDAP service name lookup. Unfortunately Oracle Internet Directory (OID) licensing is included with…

Analogies to help explain views

A not-uncommon request I hear is to explain when the contents of a view are updated. Sometimes this will be to explain the difference between a “view” and a “materialized view.” I like analogies as a tool to help describe what I’m trying to say. I wear glasses. Querying through a view is like looking…

Oracle 12c finally released!

I’m disappointed with the container licensing. Seems odd to publish with a “consume more resources than needed” option turned on. Of course, people will want to buy the containers to take full advantage of their hardware. So I guess I can understand the sales model but from a branding perspective publishing with the brakes locked…