Postcode woe

I am at the moment working my way through a huge set of postcode data for a client for mapping display.  While using postcodes is a great way of simply mapping locations,  I am often perplexed by the entire postcode schema.  Some are 7 characters,  some are 6 or less.  Some datasets use extra spaces to make all data 7 characters,  some don’t. This tends to raise problems when converting to coordinate points.  Still,  it’s all part of the challenge,  and can usually be overcome,  albeit with a fair amount of head scratching!