Category Archives: Databases

Migrate legacy application using Oracle 10g to Oracle 12c

After upgrading my developement Oracle database to 12c I discovered that an old legacy application still under support was no longer working throwing the following Oracle error: After some digging I found the following reported bug: Bug 14575666 In 12.1, the default value for the SQLNET.ALLOWED_LOGON_VERSION parameter has been updated to 11. This means that… Read More »


Create local users in #Oracle 12c

One of the most annoying things is when some vendor decides that it is a good idea to change some very basic and long time existing basic behaviour. In the new Oracle 12c you are no longer able to create local users the old way as sys: If you try to execute the above the… Read More »

#SQL to find dependency between tables in #Oracle database

There are times when we need to find which are the tables that depend on a given table. This is useful when cleanup or archiving jobs have to pe performed and the interconnection of constraints is becoming a nuisance. Lucky for us in the case of Oracle database is quite simple to search through all… Read More »

Investigate #Oracle #deadlocks

Sometimes we may end up having some application resources competing for the same resource on our Oracle database. This is usually the case when some exclusive resource must be allocated or updated as in the case of database based locking mechanisms. If there are code issues we may end up in a deadlock situation when… Read More »

Drop a not null constraint with #SQL

Sometimes very annoying things can be removed with a simple SQL commands which nobody remembers because is used so rarely. For example when we have to update a database schema and remove a not null constraint on a column. There is a short one liner for it: ALTER TABLE my_table ALTER COLUMN name DROP not… Read More »

Optimizing DELETE operations on big tables in #DB2

Deletes go very slow if the log buffer size is too small and we delete lots of data from big tables. It is very important to have the right settings for log buffer size to avoid having to frequent writes to the disk, writes that cause a high IO traffic that will slow down the… Read More »