Comparing DATA Step and PROC SQL Views


To help you decide between a DATA step view and a PROC SQL view, consider the characteristics of each type of view:

  • DATA step views

    • DATA step views are versatile because they use DATA step processing, including DO loops and IF-THEN/ELSE statements.

    • DATA step views do not have write capability; that is, they cannot directly change the data that they access.

    • There is no way to qualify the data in a DATA step view prior to using it. Therefore, even if you need only part of the data in your data view, you must load into memory the entire DATA step view and discard everything that you do not need.

  • PROC SQL views

    • PROC SQL views can combine data from many different file formats.

    • PROC SQL views can both read and update the data that they reference.

    • PROC SQL supports more types of WHERE clauses than are available in DATA step processing and has a CONNECT TO component that allows you to easily send SQL statements and pass data to a DBMS by using the Pass-Through Facility.

    • You can also use the power of the SQL language to subset your data prior to processing it. This saves memory when you have a large view, but need to select only a small portion of the data contained in the view.

    • PROC SQL views do not use DATA step programming.




SAS 9.1.3 Language Reference. Concepts
SAS 9.1.3 Language Reference: Concepts, Third Edition, Volumes 1 and 2
ISBN: 1590478401
EAN: 2147483647
Year: 2004
Pages: 258

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net