I have attached testdata.xls file.
Here is the issue, look at Obs # 1.
How can I make obs # 1 that should mimic to obs # 2 ?
Somehow file got corrupted, and contents splitted and shifted one column to the right in obs # 1 Column A (obs # 1),
Obs # 2 is correct way of representation of data.
In Obs # 1,
Salesman_name_dept should be : Michael Perry A001 Manufacturing
Sale_date should be : 10-Jan-09
Reorder should be : 50
Event should be : 10
BuySell should be : 45.45
Amount should be : 5000.75
Appreciate any help !
Issue has been resolved. Thanks to SAS communities members !
- GPatel
Many users here don't want to download Excel files because of virus potential, others have such things blocked by security software. Also if you give us Excel we have to create a SAS data set and due to the non-existent constraints on Excel data cells the result we end up with may not have variables of the same type (numeric or character) and even values.
Use this link to create a data step that you can post as text or attach as a text file for better description of your data: https://communities.sas.com/t5/SAS-Communities-Library/How-to-create-a-data-step-version-of-your-dat...
It also helps to provide the layout of the expected results.
You can repair your data-set by overriding 1st observation values.
Pay attention to variables type: CHAR or NUM to write the correct values as correct litterals;
data new;
set old;
if _N_ = 1 then do;
Salesman_name_dept = "Michael Perry A001 Manufacturing";
Sale_date = '10Jan09'd;
Reorder = 50;
Event = 10;
BuySell = 45.45;
Amount = 5000.75;
end;
run;
Issue has been resolved. Thanks to SAS communities members !
- GPatel
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
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.