Author Archives: Joachim Selke

How to move a table to a different tablespace in DB2

Recently I had to move a table of some DB2 database to a different tablespace (building an index required a larger page size). At first, I suspected changing tablespaces to be one of those complicated operations that essentially require you … Continue reading

Posted in DB2 | 14 Comments

Computing the Levenshtein Distance with DB2

The Levenshtein distance is a standard tool in approximate string matching. Despite its popularity, DB2 does not provide a build-in function for computing Levenshtein distances. What seems to be most similar in spirit is DB2’s DIFFERENCE function, which measures the … Continue reading

Posted in DB2 | Leave a comment

How to Prevent Adobe Reader’s RPM File from Installing the Browser Plugin

Adobe provides an RPM file for installing the Linux version of Adobe Reader. Unfortunately, this RPM file automatically installs the Reader’s browser plugin, which I find quite annoying. I created a simple snippet of Bash code that modifies Adobe’s original … Continue reading

Posted in RPMs | Leave a comment

Data Movement in DB2

Some time ago, I wanted to backup a complete schema of my DB2 database (version 9.5) to a file such that I am able to restore it when needed. Up to then, I always used the db2move utility for such … Continue reading

Posted in DB2 | Leave a comment

Grant Schema-Wide SELECT Permission in DB2

When managing user permissions in DB2 (version 9.5), sometimes one wants to grant the SELECT permission to all tables within a given schema. Unfortunately, this isn’t possible; only the schema permissions ALTERIN, CREATEIN, and DROPIN can be granted in DB2, … Continue reading

Posted in DB2 | 6 Comments

Using Fedora’s OpenJDK with MATLAB

Since MATLAB requires Java for some of its features (e.g. for displaying the GUI or running Java programs within MATLAB), it ships with Sun’s Java Runtime Environment (JRE). Most people already have installed a JRE on their system that usually … Continue reading

Posted in MATLAB | 5 Comments


The SQL standard defines a TRUNCATE TABLE command, which deletes all data contained in a table. Unfortunately, DB2 for Linux, UNIX, and Windows does not support this command yet (version 9.5). Strangely, it is supported in DB2 for z/OS since … Continue reading

Posted in DB2 | 5 Comments