Hi All, I need a SAS program which extract only two variables from a dataset (.dat, .txt or .cum file) that has more than 30 variable data. For Example: An input .dat file contains 25 variables. However i want to pull only the 18th and 22nd variable in my SAS output file. Condition is I dont want to define all 25 variables in my SAS program. Only the 2 variable names, length and position should be mentioned in program. Basically, I need this program for a QC purpose wherein - if one variable has a value, then the second should be Blank. If both values are present then such data is of interest. Its a kind of filter that is required. I can use the IF and ELSE statement to populate or delete the data in output. However not sure how to filter the larger data into only area of interest. I have attached a sample .dat file. Kindly request to provide a solution for my requirement. Thanks, Harsha
... View more