They say you learn something new every day.

Posts tagged ‘databases’

Second Highest Value (02/04/2012)

I had to get the second highest value from a database today. Something that I thought was going to be really difficult. But actually, it wazs fine:

SELECT MAX( col ) FROM table WHERE col < ( SELECT MAX( col ) FROM table )

Lost in the Noise (23/03/2012)

It scares me when I don’t have a way of checking whether something has been done.

At work, my Software Team claim they’d migrated all of an old database into a new database. They did it just before I started, and they said it had all been done.

Today, I went into the back end of both databases, did an export into excel, and then just a vlookup on one of the key columns.

What do you know, of the 47,000 records in the original, 15,000 were missing from the new system.

I’ve picked a dozen or so, and asked them to check them to see what they say. It’s a bit difficult, but they seem to key a lot of things manually, and keying 15,000 records manually is an awful prospect. Particularly since they’re about to get a consultancy company in to review how they’ve set up their system. It’s all wrong.

The difficult thing is, when you know it’s wrong, how do you package it up in such a way that it gets fixed. My co-worker has been ranting and raving ineffectually for the last nine years and nothing ever gets fixed.

I think what I’ve learnt here is that you need to be able to check results thoroughly, and if they’re not right, you need to have a way of packaging it all up into a project and then get it fixed. I’m good at checking things. Scripts, deltas, that sort of thing is fine. The packaging it up and getting it fixed is the harder thing. And if I’ve learnt anything about that, it’s that you have to go to an equivalent manager on the other side to get it fixed, and present it as a complete piece of work with definite deliverables. Anything else and it gets lost in the noise.

Tag Cloud