Do you need to combine data sets? How should you combine
data sets– MERGE or SET statements in DATA steps,PROC
APPEND,PROC SQL?

Answers were Sorted based on User's Feedback



Do you need to combine data sets? How should you combine data sets– MERGE or SET statements in DA..

Answer / ankit

it is depend upon my needs how to join these data set if we want to join data vertically then use set otherwise for horizontal i'll use merge.

Is This Answer Correct ?    4 Yes 0 No

Do you need to combine data sets? How should you combine data sets– MERGE or SET statements in DA..

Answer / charan araveti

Append/Set:
If you want to Add/Append data to Existed/Newly created
Dataset (With same variabls)

EX: you have DATA SETS Like JAN,FEB,MAR........,DEC.
and you want to create data set like "Sales_2010"
you have to use "SET/APPEND" Statements.

MERGE:
If you want add Existed variables to DataSet you have to use
Merge.
EX: If you 2 Dtasets of one person like Personal &
Professional and you want to all details in one dataset
means you have to use "Merge" with 'BY' Statement.

Is This Answer Correct ?    4 Yes 0 No

Do you need to combine data sets? How should you combine data sets– MERGE or SET statements in DA..

Answer / vimal

proc append is best to just combine two datasets.
it appends in bulk and without have to read and send to output. it just puts the dataset in data= to dataset in base=

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More SAS Interview Questions

What is slibref?

0 Answers  


How you can read the variables that you need?

0 Answers  


what is sas metadata server? : Sas-di

0 Answers  


How do you debug and test your SAS programs?

0 Answers   Quintiles,


What are _numeric_ and _character_ and what do they do?

1 Answers   Quintiles,






What is the difference between match merge and one to one merge?

0 Answers  


Describe the function and untility of the most difficult SAS macro that you have written.

0 Answers  


data data1; input dt account; format dt date9.; cards; 1745 1230 1756 1120 1788 1130 1767 1240 ; data data2; input startdt enddt total; format startdt date9. enddt date9.; cards; 1657 1834 12300 1557 1758 16800 1789 1789 12300 1788 1345 12383 1899 1899 13250 ; proc sql; create table data3 as select * from data1 as x left join data2 as y on x.dt>=y.startdt and x.dt<=y.enddt; quit; Here, we are getting cartision product. But,I want left join report consisting of this program. It should not get duplicate values. you can modify the program also.

0 Answers  


How would you identify a macro variable? : sas-macro

0 Answers  


Approximately what date is represented by the SAS date value of 730?

0 Answers  


what is data governance? : Sas-di

0 Answers  


how to delete the duplicates by using proc sql?

3 Answers   Genpact,


Categories