Checks the accuracy of a query-expression's syntax and
semantics
without executing the expression.
VALIDATE query-expression;
|
- query-expression
-
See query-expression.
-
The VALIDATE statement writes a message in the SAS log that states
that the query is valid. If there are errors, then VALIDATE writes error messages
to the SAS log.
-
The VALIDATE statement can also be included in applications that
use the macro facility. When used in such an application, VALIDATE returns
a value that indicates the query-expression's validity. The value is returned
through the macro variable SQLRC (a short form for SQL return code). For
example, if a SELECT statement is valid, then the macro variable SQLRC returns
a value of 0. See Using the PROC
SQL Automatic Macro Variables in the
SAS 9.2 SQL Procedure User's Guide for
more information.
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.