Uploading excel in SAS rounds decimals: e.g. 7.5% -> 8%"

Import the Excel file Safeguard_Discount_Grid.xlsx using the following code:

proc import datafile='/***/Port/Safeguard_Discount_Grid.xlsx' out=Safeguard_Dis_Grid1
dbms=xlsx
replace;
run;

The issue is that the value of Loading is changed from 7.5% to 8% when imported. Please suggest a solution to keep the original data.

To keep the original data, you can specify the GETNAMES=NO option in your PROC IMPORT statement. This will prevent SAS from automatically changing the values.

Here’s the updated code:

proc import datafile='/***/Port/Safeguard_Discount_Grid.xlsx' out=Safeguard_Dis_Grid1
dbms=xlsx
replace
getnames=no;
run;

By adding getnames=no, SAS will not read the first row of the Excel file as variable names, and it will keep the original values as they are.