How to generate trace file – SQL Trace and TKPROF in Oracle
It is a frequently asked question in almost all the Oracle forums. There have had been numerous questions/posts regarding “But how to generate the trace file?” Well, it might seem a heck of a task,...
View ArticleSQL*Plus error logging – New feature release 11.1
One of the most important things that a developer does apart from just code development is, debugging. Isn’t it? Yes, debugging the code to fix the errors that are raised. But, in order to actually...
View ArticleOracle – Case Insensitive Sorts & Compares
Oracle enhanced it’s case-insensitive sorts and compares feature with 10g Release 2. Version 11g has the following types of sorts: • Binary sort • Monolingual linguistic sort • Multilingual linguistic...
View ArticleUnderstanding Oracle Deadlock
Being a database application developer, a lot of times we come across deadlock errors. We know that a deadlock detected message is actually a clue to understand that it is a application design level...
View ArticleOracle – Insert Comma separated string values into Table
This is a small demonstartion of how to insert the values of a comma separated string to a table as different rows. This is not something new, Tom Kyte has already demonstrated it lot of times in...
View ArticleORA-06503: PL/SQL: Function returned without value
An important thing regarding function, you would agree with me that, at least once a PL/SQL developer must have heard that “A function MUST ALWAYS RETURN a VALUE of proper datatype”. Having been said...
View ArticleWHEN OTHERS THEN NULL – A bug
A when others is almost always a BUG unless it is immediately followed by a RAISE. — Quote from Thomas Kyte’s excellent thread on similar topic Remember, for errors, RAISE –>...
View ArticleSQL*Plus error logging – workaround for ROLLBACK issue
In my previous post SQL*Plus error logging – New feature release 11.1, as a NOTE I stated an issue that whenever ROLLBACK is issued in the session, the feature fails to log the errors. Thanks to Jacek...
View ArticleOracle EXPLAIN PLAN – How to create, display and read
This post is to demonstrate the ways to create and display explain plan. But before we proceed with the steps of creating and displaying explain, the schema must have the PLAN_TABLE. A lot of times...
View ArticleOrder of item list in declaration part of PL/SQL anonymous block – PLS-00103
In an anonymous PL/SQL block, if you do not follow the order of the item list in the declaration part, you might just end up with PLS-00103 error. Per Oracle documentation on Anonymous Block following...
View ArticlePL/SQL Developer Settings
Being an Oracle database application developer, we come across a lot of client tools like SQL*Plus, SQL Developer, TOAD, PL/SQL Developer etc. In this post I will be explaining the most common settings...
View ArticleLock user SYS and Connect without SYSDBA
Many times this question comes up “Whether we could login as SYS but not as SYDBA”. Related questions are “Whether you could lock SYS account”. The answer to both the questions is YES. Let’s see how :...
View ArticleA myth about Row Exclusive Table Lock on SELECT FOR UPDATE with no rows
Recently I came across a question in Stackoverflow about row exclusive lock after executing SELECT..FOR UPDATE with no rows selected. The fact was that the query returned no rows, but Oracle applies a...
View ArticleV$RESERVED_WORDS & X$KWDDEF – Interesting facts!
It’s a lazy Friday and I saw an interesting question in Stackoverflow about “Why are there two “null” keywords in Oracle’s v$reserved_words view?” And I spent next 2 hours digging into knowing the...
View ArticleFind specific/similar words in a string using REGULAR EXPRESSION in Oracle
This is supposed to be one of the most common question among all the Oracle discussion forums, and especially folks looking for REGULAR EXPRESSION over web, would have definitely come across such a...
View ArticleWhy are junk values/special characters/question marks displayed on my client?
There have been numerous questions on almost all the Oracle discussion forums about “Why are junk values displayed on my client” or ” Why do I see question marks or special characters in the table”....
View ArticleFind all columns having at least a NULL value from all tables in the schema
Spending a good amount of time answering the questions on multiple Oracle forums, like OraFAQ, Stack Overflow, OTN, dBforums etc. I could now figure out the most common questions by amateurs in Oracle...
View ArticleOracle 12c Post Installation Mandatory Steps
Since 12c was made available for Windows 64bit OS Desktop class, people started using it immediately. And, some/few/most/all must have encountered issues while installation and especially post...
View ArticleSYS_OP_C2C Oracle internal function, implicit conversion and performance impact
SYS_OP_C2C is an internal function which does an implicit conversion of varchar2 to national character set using TO_NCHAR function. SQL> CREATE TABLE t AS SELECT 'a'||LEVEL col FROM dual CONNECT BY...
View ArticleSplit single comma delimited string into rows in Oracle
NOTE : This post is about splitting a single comma delimited string. If you have to apply it on a table with multiple rows having comma delimited strings, then look at Split comma delimited strings in...
View Article