January 03, 2008, 04:35 PM
<akilayko>how-to display social security# as ###-##-####
Need help with displaying the social security number in the format ###-##-####.
Thank you for your help.
adk
WebFOCUS 5.3.3
Unix
Oracle
EXL2K
January 03, 2008, 04:44 PM
GinnyJakesAssuming that your SSN is stored as integer and not alpha, you will first have to convert it to alpha. If not, skip that part. Then you can supply masking to get the desired output format.
DEFINE FILE filename
SSNA/A8=EDIT(SSNI);
SSN/A10=EDIT(SSNA,'999-99-9999');
END
Please read up on the EDIT function.
January 03, 2008, 04:53 PM
<akilayko>That was most helpful. Thank you
January 03, 2008, 06:19 PM
LeahYou can also put it in a compute statemnt if just doing a detail line, And Ginny
, SSN is 9 digits. Some systems store it as alpha so wouldn't need the first edit.
January 03, 2008, 07:00 PM
<akilayko>Thank you, Leah.
January 04, 2008, 10:44 AM
GinnyJakesLeah,
Thanks for keeping me honest. I'm not feeling well and wasn't paying attention. But I did mention that he wouldn't have to do the first edit if the field was already alpha.
January 04, 2008, 11:30 AM
LeahGinny, hope you're feeling better, and your welcome akilayko. I've had those days as well.