Minimalistic Oracle

Minimalistic Oracle contains a collection of practical examples from my encounters with Oracle technologies. When relevant, I also write about other technologies, like Linux or PostgreSQL. Many of the posts starts with "how to" since they derive directly from my own personal experience. My goal is to provide simple examples, so that they can be easily adapted to other situations.

Thursday, January 29, 2026

Compression for Postgres tables

›
In PostgreSQL you don’t create a “compressed table” in the Oracle sense. Rather, compression is achieved per-column compression via TOAST, p...
Sunday, January 25, 2026

How to detach an ORACLE_HOME to an existing inventory

›
I want to detach an existing oracle_home from my inventory. Note that the last argument must be the full path to the oracle software, NOT t...
Thursday, November 20, 2025

How to unload rows in an Oracle database to disk using sqlcl

›
In sqlcl, execute these lines to unload SCOTT.EMP to disk: set arraysize 200 set load batch_rows 200 UNLOAD TABLE SCOTT.EMP DIR /datadisk1/...

Find total size of all databases in PostgreSQL cluster

›
SELECT database, size FROM ( SELECT datname AS database, pg_size_pretty(pg_database_size(datname)) AS size, 0 AS sort_o...
Monday, November 17, 2025

Find the number of columns in a table in postgreSQL

›
SELECT count(*) FROM information_schema.columns WHERE table_name = 'mytable' AND table_schema = 'jim';
Tuesday, November 11, 2025

Exchange all occurences of a string in all files in a sub-directory structure

›
find /var/lib/pgsql/cities/aberdeen/schema -type f -exec sed -i 's/aberdeen/glascow/g' {} +

List all files containg a string in a subdirectory structure

›
grep -Rl 'aberdeen' /var/lib/pgsql/cities/aberdeen/schema Result: /var/lib/pgsql/cities/aberdeen/schema/grants/grant.sql /var/li...
‹
›
Home
View web version

About Me

My photo
Name: Vegard Kåsa
My career as an Oracle DBA startet in 2001, when I acceptet a request to take on the responsibility as my current employer's DBA. From that point and onwards, managing Oracle databases has kept me busy and engaged. I enjoy my work, and particulary appreciate the constant learning and devlopment that comes with the job. From 2014, I am self-employed through my company Oric Consulting AS (Norway), and from 2024 Oric Consulting AB (Sweden) I currently live in Göteborg, Sweden, with my family.
View my complete profile
Powered by Blogger.