In SAS, percentages are numeric ratios with a PERCENT format attached. Check with your DB designers how they want such values.
Do you write the data to DB/2 with SAS/ACCESS, or do you use text files for the data transfer?
If you attach the PERCENT format to a SAS variable, then percentages under 100 must be defined as a decimal less than 1. Your CSV will then contain contain values like below with a % suffix:
28 data _null_; 29 percentage = 0.1234; 30 format percentage percent8.2; 31 put percentage=; 32 run; percentage=12.34% NOTE: DATA statement used (Total process time): real time 0.00 seconds cpu time 0.00 seconds
As @Kurt_Bremser says, check with your DB2 admin to confirm the required data format.
I use proc export to csv
Then you need to ask your DB people how they want the data presented in the csv file. Most probably, they don't want the percent sign, but the percent value (not the ratio), so you would need to multiply by 100 and use a standard numeric format.
Oh yeah, and don't use PROC EXPORT when you need to do special conversions. Write the DATA step yourself.
Secure your spot at the must-attend AI and analytics event of 2024: SAS Innovate 2024! Get ready for a jam-packed agenda featuring workshops, super demos, breakout sessions, roundtables, inspiring keynotes and incredible networking events.
Register by March 1 to snag the Early Bird rate of just $695! Don't miss out on this exclusive offer.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.