How do you read in the variables that you need?

Answers were Sorted based on User's Feedback



How do you read in the variables that you need?..

Answer / rajesh

If you need the required variables;
go for the condiation statments or input statment or keep
and drop options, and if it is in output then var statement
in the proc print.

Is This Answer Correct ?    3 Yes 0 No

How do you read in the variables that you need?..

Answer / vijai bhaskar

if u want u read particular variables in the data step by
using input statement

Is This Answer Correct ?    2 Yes 0 No

How do you read in the variables that you need?..

Answer / ram

if u read priticular variables in data by using keep and
drop statements

Is This Answer Correct ?    2 Yes 0 No

How do you read in the variables that you need?..

Answer / harsha

Using with Var statment we can read the required variable.

Is This Answer Correct ?    1 Yes 0 No

How do you read in the variables that you need?..

Answer / natraj

In data step and Proc step you can use the data set options
such as KEEP= / DROP= .

ex: data xxx (keep=a); or data xxx ( drop= b c);
run;
proc print data=xxx (keep=a) or ( drop= b c);
run;
you can use the VAR STATEMENT in PRINT PROCEDURE to list
the desired varibles;

ex: proc print data= xxx;
var a ; /* put your desired variables */
run;

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More SAS Interview Questions

How does SAS handle missing values in: assignment statements, functions, a merge, an update, sort order, formats, PROCs?

0 Answers   Quintiles,


/*i have the following dataset.*/ data score; input marks ; datalines; 10 20 30 40 50 60 70 80 90 100 ; run; Now i should get the result as sum of 1 to 5 i.e(10+20+30+40+50)=150 and 2 to 6 i.e(20+30+40+50+60)=200 and 3 to 7 i.e(30+40+50+60+70)=250 and so on. how to get it. thanks in advance

2 Answers   Eval Source,


what are sas/access and sas/connect? : Sas programming

0 Answers  


What do you feel about hardcoding?

1 Answers  


Describe what are the different levels of administrative users in sas? : sas-grid-administration

0 Answers  






how do you validate tables abd reports?

2 Answers   Accenture, Quintiles,


How do you read in the variables that you need?

9 Answers   Accenture,


Why do we use QUIT commmand for proc datasets and proc sql ???

3 Answers  


What sas features do you use to check errors and data validation?

0 Answers  


how to shift the rows to cols? eg: i have like field1 field2 field3 10 20 20 this should be displayed as field1 10 field2 20 field3 30 (without the obs col) how do this?can i use transpose or tell me suitable way to do this?

3 Answers   CMC,


i am importing large data from oracle to work library. in log there is a error message worklibrary space is not enough. then how to import the data safely to sas environment.

2 Answers   Cap Gemini,


what are sas bi dashboard components? : Sas-bi

0 Answers  


Categories