The Run a SAS Program
directive provides the primary means of submitting user-written SAS
code in SAS Data Loader for Hadoop. The code runs as you submit it,
without the code generation step that is used in other directives.
The code that you submit generates the same log and error information
as in other directives. Also, the running code is tracked in the Run
Status directive, and you can save and reuse jobs in Saved Directives.
The code execution process
begins and ends in the vApp. The Workspace Server inside the vApp
runs the code and executes all Base SAS language elements. If your
code contains procedures that are enabled for DS2, or if your code
contains native DS2 methods, then that code might be passed into the
Hadoop cluster for execution. In your Hadoop cluster, DS2 code is
executed by the SAS In-Database Code Accelerator for Hadoop.
Upon completion of DS2
execution on the cluster, the vApp receives notification and continues
or concludes execution in the local Workspace Server.
For examples of DS2-enabled
SAS code, refer to the code that is generated by directives such as
Transform Data in Hadoop.
CAUTION:
Data sets
in Hadoop are of indeterminate size. Any data that is indiscriminately
returned from Hadoop to the vApp can overload the client.
To avoid overloading
the vApp, your SAS programs need to minimize or eliminate the transfer
of data from Hadoop to the vApp. It is generally preferable to define
a result set or target table that remains in Hadoop. You can then
analyze the data in Hadoop, or load data for further analysis onto
a grid of SAS LASR Analytic Servers.
Note that you can generate
code in any of the following software, and copy and paste that code
into the Code task of the Run a SAS Program directive:
-
SAS Data Management Studio
-
-
SAS Data Integration Studio
Conversely, you can copy the code that is generated
in any SAS Data Loader directive and paste into any SAS text editor.
One suggested location for pasting SAS Data Loader code is the SAS
Code Node in DataFlux Data Management Studio.
To run DS2 code directly
in Hadoop using the SAS In-Database Code Accelerator, see the “SAS
In-Database Code Accelerator for Hadoop” section of the SAS In-Database Products: User's Guide.
User-written SAS DS2
code can be submitted in an expression builder in the following directives:
-
-
Cleanse Data in Hadoop (Filter
Transformation)
-
Transform Data in Hadoop (Filter
Data task)