Month: January 2011

Gzip in python

We have a large text file containing 325 million integer values that we need to load into a database. The file uncompressed is about 4.5GB. Even though disk is cheap, we didn’t have enough readily available to quickly decompress the…

Handling constraints when truncating a table

Oracle doesn’t supply a TRUNCATE TABLE TABLE_NAME CASCADE CONSTRAINTS syntax structure as it does when dropping a table. The anonymous block below will truncate all tables in the current schema and handle the constraints violations (foreign keys) that may be…

Dumping Oracle DDL part two

Below is a python script that strip the double quotes from the output of dbms_metadata.get_ddl, as well as the storage clauses. The initial clause is often far too high, so this allows you to extract the DDL and run it…

History of computers

I found this interesting link while searching for something else. It is a fairly complete history of computer technology from the time before Christ to 2003. Enjoy.