Multiple choice technology platforms and products

data a; one=1; run; data b; set a(in=a) a(in=b); if a and b; run; How many observations in dataset b?

  1. 0

  2. 1

  3. 2

  4. Error

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

In SAS, when you set the same dataset twice in one SET statement, the in= variables track which source contributed the current observation. Because set a(in=a) a(in=b) processes observations sequentially, a and b are never both true at the same time, resulting in 0 observations.