Hi Art297, Thank you very much. I have replaced the lengths with best32., it worked. No more awkward values for “ACCOUNT_NUMBER” in the created data set “want”. BTW, what is the difference between optimum for file size and readability? proc sql; create table want as select min(bank_number) as bank_number , left((put(min (ACCOUNT_NUMBER),best32.))) as ACCOUNT_NUMBER , min(country) as country , left((put(min(branch_number),best32.))) as branch_number , min(currency_code) as currency_code , max (POST_DATE) as POST_DATE Format=date9. , max (EFFECTIVE_DATE) as EFFECTIVE_DATE Format=date9. , sum (PRINCIPAL) as sum_PRINCIPAL , sum (Write_off_Total) as net_Write_off_Total from a.post_this_data group by account_number ; quit; Hi Ballardw, When I ran the above code on the attached data set, the values I get for two "date-related" variables are like below. How could I get date9. format? post_date effective_date ********* *********** ********* *********** ********* *********** Thanks Mirisage
... View more