text - Express "PUT all variables" in a data step to export SAS data -


Target: Export a complete SAS dataset in a tab-delimited text file using a data step.

Problem: I think in every example, like, after the statement of the statement, each variable must be specified in the data phase. Is there no easy way to ask for only "all" variables?

I have already tried to use PUT _ALL_ , but it includes only the output names for variable names in each row of the output, rather than these values .

If you want to do this in a data phase, and do not want to specify things, But in reality you do not want to do the PROC export , you want to make a decision, and that data is easily specified in a particular format), you can do this.

  proc sql; Select the name: The name list is separated by ''. In the column where libname = 'SASHELP' and memname = 'CLASS'; * You want the name to be libname / dataset; leave; Filename Blah Temporarily; Data_null_; Set sashelp.class; File blah dlm = '09'x; Put and list Run;  

You can customize something by modifying the SQL query based on your needs (like you have a set of variables with _date , maybe you modify it For those people, call name || ': date 9.' ' in the SQL query.

Note that the slip name / memname / name field in the dictionary is usually The upper case is not always the upper case, I do not think, but they are almost always. Some RDBMS can override this for anecdote, I believe).


Comments

Popular posts from this blog

import - Python ImportError: No module named wmi -

Editing Python Class in Shell and SQLAlchemy -

c# - MySQL Parameterized Select Query joining tables issue -