When I was involved in NPFiT (Community NHS Electronic Records area) we had so many issues with addresses and vendor systems not being properly compliant with the NHS Demographic Spine (PDS). You also have to be able to hold records with no fixed address, temporary addresses, addresses of POA, withheld addresses (either from people allergic to tech or for safeguarding reasons).
Even something as simple as matching a postcode gets thrown off if the spaces are in the wrong place, so you have to normalise postcodes, add more code to check the postcode is in a valid format etc.
One of my first jobs in IT was to "sanitise" the customer database of postcode starting with SO
it was often entered as S0 and that caused the letters to be sorted in the wromg order
and hence the Post Office charged us a lot extra rather than the huge discount for pre sorted mail
Well THAT grew rather beyond its initial concept
I started with SO being S0
then found something else - then something else and so on
ended up having a program that changed abotu 50 different things that were always keyed in wrong
in the meantime the Techy guy was writing a subroutine to make the input correct by the proper standards
Then later I became the Techy guy and they found another problem and I ended up changing it again for several different postcode that were still being entered wrongly
Little funny thing
one of the things I was called out to look at when we got the whole thing sorted was one user's computer crashing when she was entering the postcode
everyone else was OK - but her's crashed several times a day
anyway - I went to talk to her - which pleased her as talking to a "manager" always meant they went onto "average perfromance" wages - whcih meant they didn;t have to work hard for the rest of the day
anyway - we chatted and she went back to working - it was a cll centre place getting orders over the phone
all went well - no crashes
then she got a call - and started entering the address
but it turned out that customer had a question not relavted ot orders and stuff - so the operator
who was female - which will matter in a minute
leant over to get a catalogue from the person next to her
and as she leant over the computer crashed
but I saw what caused it
firstly - she was a big girl in the chest department
and when she leant over her right breast pressed down on the zero button on her keyboard
which I then had to explain to the large Scouse woman
which caused an exclamation of "Oh My GOD - It was me right t*t" - (direct quite - and it was quite loud)
turned out that the post code verification rules mean that 00000000 is technically a valid postcode
but the computer system (a bit that I did) then needed, some some reason I can;t remember, to divide by something in it
which crashes any computer with Divide by Zero errors
which clearly became known as "The Right T*T problem) and went down in legend