Joined: 28 Jul 2006 Posts: 1702 Location: Australia
Hi,
if I understand it correctly, you want the full name ie. first name initial and last name reversed and sorted with longest name first
ie. longest name=lastname + initial + first name
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
Ramsri,
I think Gerry was just showing an example, since you've kept any details to yourself.
You, surely, know what the maximum length of the elements of the name can be, and that gives you the theoretical maximum length needed. If your field already exists in that form (firstname, initial, lastname) only, then it is just the length of that field itself that you need to work with. The maximum length for an individual item for the FIXLEN is (field-length - 1 - 1 - 1 - 1). 130 seems a reasonable length, to guess, that would hold all your data, and may be much longer than need. You know your data, we don't.
The IFTHEN is just getting a "true", so is unconditional. I think another IFTHEN=(WHEN=INIT would be better.
I suggested JFY rather than SQZ due to the potential of embedded blanks in names. I assumed you had the rearrangement dealt with and were just keeping it a secret.