O'Reilly logo

SAS Certification Prep Guide: Base Programming for SAS 9, Third Edition by SAS Institute

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 21: Reading Hierarchical Files

  1. When you write a DATA step to create one observation per detail record you need to
    1. distinguish between header and detail records.
    2. keep header data as a part of each observation until the next header record is encountered.
    3. hold the current record so other values in the record can be read.
    4. all of the above
    Correct answer: d
    In order to create one observation per detail record, it is necessary to distinguish between header and detail records. Use a RETAIN statement to keep header data as part of each observation until the next header record is encountered. You also need to use the @ line-hold specifier to hold the current record so other values in the record can be read.
  2. Which ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required