In PROC PRINT, can you print only variables that begin with
the letter “A”?

Answers were Sorted based on User's Feedback



In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / hsong001

Use the idea of variable list (varlist) wildcard :

e.g.,
proc print data=xxx ;
var A: ;
run ;
This will list all variables start with letter A.

Is This Answer Correct ?    16 Yes 6 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / a

proc print data=;
where name like 'A%';
run;

Is This Answer Correct ?    3 Yes 3 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / ashish

proc print data=datset(obs=5) ;
var s:;
quit;

Is This Answer Correct ?    0 Yes 0 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / henry

proc print data=sashelp.class;
var height weight;
where upcase(substr(name,1,1))='A';
run;

Is This Answer Correct ?    1 Yes 3 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / parbhat517

PROC PRINT DATA = X;
WHERE SUBSTR(NAME,1,1) = 'A';
RUN;

Is This Answer Correct ?    0 Yes 2 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / naveen

proc sql;
select *
from qqq
where name contains "A";
quit;

Is This Answer Correct ?    0 Yes 4 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / sunil chilaka

Dear fndz to print only variables that begin with
the letter "A" we can use

keep=option

Is This Answer Correct ?    2 Yes 7 No

In PROC PRINT, can you print only variables that begin with the letter “A”?..

Answer / naveen

proc print data=abc;
var name;
where name contains="A";
run;

Is This Answer Correct ?    0 Yes 8 No

Post New Answer

More SAS Interview Questions

in ods is there any lib's

2 Answers   SAS,


whenever we using the merging through data set merging ,we can get note in log like this "MERGE STATEMENT HAS MORE THAN ONE ONE DATASET BY REPEATED BY VAIABLES" but the output has come in good manner,whenever in in sql(full join) we can get cartion product.so How do overcome this problem in sql?

1 Answers   Accenture,


what are the categories that sas informats are used to the place the data? : Sas-administrator

0 Answers  


what is factor analysis? : Sas-administrator

0 Answers  


what is the main difference between rename and label? (don't say that they both perform the same function).

11 Answers   Parexel,






what are the different ways of merging two datasets.name atleast 4.

2 Answers  


What do you feel about hardcoding?

3 Answers   Pfizer,


explain what is factor analysis? : Sas-administrator

0 Answers  


How to do user inputs and command line arguments in SAS? D&B

2 Answers   BoA, Quintiles,


what are system option ? give few examples ? what are dataset options and dataset statements ? if there is a keep option and keep statement ? which one is executed first ? Difference between a WHERE statement and IF statement ? what is the advantage of using WHERE statement option on the dataset ?

1 Answers   Satyam,


What are the default statistics for means procedure?

0 Answers  


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

0 Answers   Quintiles,


Categories