[Phpwm] Cleaning up addresses

Phil Beynon phil at infolinkelectronics.co.uk
Tue Mar 20 11:24:07 GMT 2007

> I really must be missing something here Phil when you say
> adjacent postcodes
> are you using this / were using this to work out the nearest location of a
> relevant resource or service... i.e. you nearest shop is in postcode XYZ
> I just be interested to know what the problem was you put the solution in
> for as it still seems overly complicated

I can't see why anyone wouldnt want to use this as a solution, since it is
the most elegant.

OK - you are on a building site in Leicester LE5, you need a bag of cement.
You enter the postcode you are in, it searches against the builders
merchants table, it doesn't find one. So it then expands out one ring of
adjacent postcodes and finds 3 builders merchants. Apart from in the
Highlands most of the postcode areas are relatively small, so this is an
efficient way of searching for things.
We had about 370 different types of datasets, and plans for many more -
these were coming form a wide variety of sources and all in slightly
different formats. Using this method all we had to do was explode the first
and second half of the postcodes into seperate fields at which point the
data had an indexable commonality.
Essentially it allowed it to take data and add it in very quickly, or update
existing data without any field preprocessing tailored to that dataset.

So yes, internally it was complicated, which is what computers are good at,
but it could be driven by anyone with about 5 mins of training.


More information about the Phpwm mailing list