what are the best ways to read the large data into SAS without creating the dataset to find out the whether the data is allined
You will need to provide quite a bit more detail and explanation for us to be able to give you advise.
On a high level: You can use DATA _NULL_; which will allow you to process data without writing anything to a target table (_NULL_).
1. If you want to verify your code without runing a large load then you can use options obs=0
2. If you want to validate or check the data then you can control the data load to sas using options obs=<number of records>
3. If you want to validate the code with the wholde data file then you can use data _null_;
4. If you want to read the data efficeintly, use proc copy or proc dataset if both source and target are using similar db engine.
I am assuming that by "aligned" you mean the data is valid? I also assume that your using proc import. Switch your programming to use a datastep read - as suggested by @Patrick, use a data _null_ is you don't want to save the file. In the datastep read, specify each variable, informat, length, format, label etc. In this way once the code is executed, anything which doesn't conform to your structure will show problems in the log with the actual line of data which causes the issues (up to what you have set your options level to). There is no way to do this without reading at least header and first observation of the file.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.