SAS OnlineTutor HomeFAQ PageSuggested Learning PathsContents+Searchback||next

Performing Queries Using SQL
PROC SQL Basics


PROC SQL  is SAS software's implementation of Structured Query Language, or SQL, a standardized language that is widely used to retrieve and update data in tables and views based on those tables.

The chart below compares data processing terminology, SAS terminology, and SQL terminology.


Date Processing SAS SQL
File SAS Data Set Table
Record Observation Row
Field Variable Column


You can use PROC SQL to
  • retrieve and manipulate SAS tables
  • add or modify data values in a table
  • add, modify, or drop columns in a table
  • create tables
  • generate reports.

PROC SQL also enables you to join multiple tables in fairly sophisticated ways, even if the tables do not contain a common variable.

In addition, PROC SQL lets you combine data from two or more different types of data sources and present them as a single table. For example, you can combine data from two different types of external databases. Or you can combine data from an external database and a SAS data set. 


External databases and SAS Data Set boxes


back||next


Copyright © 2002 SAS Institute Inc., Cary, NC, USA. All rights reserved.

Terms of Use & Legal Information | Privacy Statement