By admin | August 10, 2009

SAS Certified Adv Programmer 50 Questions (2)

Given the following SAS data sets One and Two:

One

Year Qtr Budget
2001 3 500
2001 4 400
2002 1 700

Two

Year Qtr Sales
2001 4 300
2002 1 600

The following SAS program is submitted:

proc sql;
    select one.*, sales
    from one right join two
    on one.year=two.year;
quit;

Which of the following reports is generated?

a.

Year Qtr Budget Sales
2001 3 500 .

b.

Year Qtr Budget Sales
2001 4 400 300
2002 1 700 600

c.

Year Qtr Budget Sales
2001 3 500 .
2001 4 400 300
2002 1 700 600

d.

Year Qtr Budget Sales
2001 3 500 300
2001 4 400 300
2002 1 700 600

3 comments | Add One

  1. admin - 08/10/2009 at 9:31 pm

    D

  2. Raji - 08/22/2012 at 1:21 am

    Should’nt it be B? Becoz the right join while picking up common obs retains the exclusive right table rows. Since there are no exclusive right table rows, it picks up the common rows. Pl clarify.

  3. Blaiso - 05/31/2013 at 7:45 pm

    D, matching rows + non matching row from the right. no non matching row from the right

Leave a Comment

Leave a Reply

Your email address will not be published.