Support 805.461.7300
Sales
Our Technology. Your Success.

Insert Space in Full name

This command will take a name in the field called First that is formatted like this:
JohnSmith
(where the first and last name are together without a space and the last name has a capital letter)

and make it: John Smith

With your name in the field called first, pull down the Edit menu to Command, then run the command below:

com_Char=65
com_Field="FIRST"
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
com_Char=com_Char+1
REPLACE &com_Field WITH LEFT(&com_Field,1)+STUFF(SUBSTR(&com_Field,2),AT(CHR(com_Char),SUBSTR(&com_Field,2)),0," ") ;
    FOR AT(CHR(com_Char),SUBSTR(&com_Field,2))>0
REPLACE ALL &com_Field with REDUCE(&com_Field)

« Back to Commands

I am especially motivated to take time to draw attention to Vince. In two instances, we potentially faced loss of product – significant loss, but thanks to everyone’s efforts, most notably Vince’s, we ended up with minor re-work and zero loss of stock. He’s patient and thorough, knowledgeable and resourceful. And he’s patient – A Big Plus when dealing with me. Long story short, the guy was able to not only produce a solution, but to prove to me the veracity of it. I hung up the phone saving thousands of dollars in catalog stock, not lost but salvaged, and my department had to spend just a wee bit of time on job re-work (which I was happy to do, all things considered). But I also hung up with a peculiar urge to write about Vince, incongruent as that may be since I rarely am moved to write letters of this sort. So… In a time of crisis, Vince was a terrific asset and ally. If I were his boss, I’d attempt a merit raise authorization, he was that exceptional.
H.D., Shawnee Mission, KS