Hi all,
I have been tasked with some string manipulation and today must be my bad head day as it is proving more difficult than I expected.
I have to take the initials of the first and second and third name from the first and second and third columns along with any surnames
The reason is we have to fit the long names onto cheque books for customers we are taking on from another company.
Plus we need to keep the title.
Here is an example of the long name as it stands now:
so, here is what I have been trying after some searching on the web:
that gets the initials, but only the first 2
gets the surname but isn't working correctly.
am I over thinking this, or under thinking it?
What is my best approach to the data?
thanks
Philip
I have been tasked with some string manipulation and today must be my bad head day as it is proving more difficult than I expected.
I have to take the initials of the first and second and third name from the first and second and third columns along with any surnames
The reason is we have to fit the long names onto cheque books for customers we are taking on from another company.
Plus we need to keep the title.
Here is an example of the long name as it stands now:
as you can see, these could be considered to be joint bank accounts between 2 or even 3 persons. on the cheque books we will have to put the title, which could be Mr, Miss, Ms, Dr, Doctor, or even (heaven help us) Messrs along with the initials of the first and second names and the full surname, and the total should be less than 35 characters !Mr C Chrysostomou & Mr N Chrysostomou & Mrs A Chrysostomou
Mrs M Karseras & Ms P Hadjisoteriou & Mrs E Athanasiou
Mrs A Theodorou & Mr A Aristotelou & Mrs G Naziri & M Karmiou
Mrs L Vazanias & Mrs G Braithwaite & Mrs Helen West
Mrs L Vazanias & Mrs G Braithwaite & Mrs Helen West
Mrs Olympia Pieridou & Mrs T&mr M & Mr C & Mrs K Michaelides
Miss J A Santamas& Mrs M T Santama- Solomonides& Mrs Lida Santama
Miss J A Santamas& Mrs M T Santama- Solomonides& Mrs Lida Santama
Mr Polydoros Polydorou & Mrs Maro Themistocleous & Mrs Sylvia Polydorou
Mr Themis & Mrs Androulla & Mr Nicholas & Mrs Vasso Gina Demetriou
Mrs S K Makkofaides & Mr Z Koullas & Mrs Y Koullas & Mrs R Kleopa
Mr G Zorzy & Mrs H Louca Zorzy & Mr S Stavropoulos & Mrs Y Stavropoulos
Mrs M Franceschina & Ms C Eugeniou & Ms O L Toumazides T/a The Three Cupcakes
Mr David & Mrs Eileen Nixon D.h.nixon & Co. - Office Account
so, here is what I have been trying after some searching on the web:
Code:
=IF(LEN(TRIM(E:E))-LEN(SUBSTITUTE(TRIM(E:E)," ",""))>=1,MID(TRIM(E:E),FIND(" ",TRIM(E:E))+1,1),"")& " " &IF(LEN(TRIM(E:E))-LEN(SUBSTITUTE(TRIM(E:E)," ",""))>=2,MID(SUBSTITUTE(TRIM(E:E)," ","",1),FIND(" ",SUBSTITUTE(TRIM(E:E)," ","",1))+1,1),"")
Code:
=RIGHT(J:J,LEN(J:J)-FIND(" ",J:J)+1)
am I over thinking this, or under thinking it?
What is my best approach to the data?
thanks
Philip