Previous Page
|
Next Page
SQL Procedure
Syntax
Procedure Syntax
PROC SQL Statement
ALTER TABLE Statement
CONNECT Statement
CREATE INDEX Statement
CREATE TABLE Statement
CREATE VIEW Statement
DELETE Statement
DESCRIBE Statement
DISCONNECT Statement
DROP Statement
EXECUTE Statement
INSERT Statement
RESET Statement
SELECT Statement
UPDATE Statement
VALIDATE Statement
Overview
Examples
Creating a Table and Inserting Data into It
Creating a Table from a Query's Result
Updating Data in a PROC SQL Table
Joining Two Tables
Combining Two Tables
Reporting from DICTIONARY Tables
Performing an Outer Join
Creating a View from a Query's Result
Joining Three Tables
Querying an In-Line View
Retrieving Values with the SOUNDS-LIKE Operator
Joining Two Tables and Calculating a New Value
Producing All the Possible Combinations of the Values in a Column
Matching Case Rows and Control Rows
Counting Missing Values with a SAS Macro
SELECT Statement
Selects columns and rows of data from tables and views.
Restriction:
The clauses in the SELECT statement must appear in the order shown.
See:
SQL SELECT Statement Clauses
table-expression
query-expression
Syntax
Syntax
SELECT
<DISTINCT>
object-item
<, …
object-item
>
<
INTO
macro-variable-specification
<, …
macro-variable-specification
>
>
FROM
from-list
<
WHERE
sql-expression>
<
GROUP BY
group-by-item
<, …
group-by-item
>
>
<
HAVING
sql-expression>
<
ORDER BY
order-by-item
<, …
order-by-item
>
>
;
Copyright © SAS Institute Inc. All rights reserved.
Previous Page
|
Next Page
|
Top of Page