Apr 26

Installing Python3/Spyder on Linux Mint 17


sudo apt-get install python3-pip python3-pyqt4
sudo pip3 install spyder
sudo pip3 install rope

Apr 11

List tables without Primary Keys in a DB2 database


--
-- List DB2 base tables which don't have Primary Keys
--
SELECT tb.TABLE_SCHEMA, tb.TABLE_NAME, 'has no Primary Key'
FROM SYSIBM.TABLES tb
LEFT OUTER JOIN SYSIBM.SYSCOLUMNS sc ON sc.TBNAME = tb.TABLE_NAME AND sc.KEYSEQ > 0
WHERE tb.TABLE_TYPE = 'BASE TABLE'
AND tb.TABLE_NAME LIKE '%'
AND sc.NAME IS NULL

Dec 30

Plastic recycling

From time to time I need a big lump of plastic to construct something in my workshop.  Suitable pieces are usually either difficult to find or expensive, so I’ve been looking for alternatives which preferably use material which would otherwise go to landfill.

After watching this video about recycling HDPE (#2) plastic, I bought a toaster oven and gave it a try.

Step 1: collect (and wash) milk bottles:

plastic000

Step 2: remove labels (this is easier if you first heat the labels using a hair dryer):

plastic001

Step 3: cut into strips and pack tightly into soup cans.  Bake in toaster oven at 190C until molten:

plastic002

Step 4: allow to cool, and cut soup can off the slug:

plastic003

While this worked, it was a little too labour-intensive for my liking. I tried using heavier-gauge HDPE plastic from buckets and water jugs, but unfortunately these will only soften to the consistency of chewing gum, and need some type of press to squeeze them into the desired shape.

After looking around for a while I found these polypropylene (#5) plastic tubes, which were originally the cores from rolls of paper:

plastic004

Cutting these into soup-can-sized lengths is very quick, at which point they can be slit lengthwise and coiled up to fit inside each other inside the can.  As an added bonus, this plastic “flows” much more easily once it has melted:

plastic005

Once again it’s usually necessary to cut the can away once the slug has cooled:

plastic006

Lately I’ve been rebuilding a 54″ lawnmower cutting deck, and I needed to fashion some new anti-scalp rollers for the front and rear.  These need to be about 100 x 250mm cylinders, and since the deck belongs to a John Deere the ideal colour scheme is green/yellow:

plastic007

A little searching at my local recycling centre turned up a cracked and broken children’s sandpit, made from polypropylene:

plastic008

As usual, this was cut into strips and packed into tin cans (this time 1.2kg dog food cans, to get the right diameter and length):

plastic009

This particular batch of plastic had enough shrinkage to allow easy removal of one of the slugs from the can once it had cooled (I still needed to cut the second can off:

plastic010

The blue polypropylene plastic in this image came from several electrical cable spools.  In this case I’m using some old teflon-coated cookware as the moulds:

plastic011

Unfortunately I still needed to cut away the round pan once the plastic had cooled, so now I line any pans that I want to recycle with baking paper before packing them with plastic strips.

 

Dec 11

In the beginning…

…we needed a starting post which included an image file, just to prove that it would work.

So here’s a screen shot of Microsoft Excel, running under Windows 3.1, on DR DOS 7,  inside VirtualBox, on a Linux machine.

VirtualBoxDRDOS7