BeOptimized - Tips and Tricks

Run PROC FEDSQL in CAS for SAS users

SAS Viya is the latest enhancement of the SAS Platform. When you are SAS9 programmer you can continue using your SAS9 syntax in SAS Viya. However, if you want to take advantage of capabilities such as parallel processing or in memory processing offered by SAS Viya, you need to know a little bit more than SAS9 syntax.
PROC FEDSQL can be executed in CAS and the syntax looks like the PROC SQL syntax. However, it is totally incorrect to say that you could copy paste Proc SQL statements/clauses into Proc FEDSQL. This tips and tricks is designed for people who already know PROC SQL and think that PROC FEDSQL is the replacement of PROC SQL.

Details

When I started with Proc FEDSQL in CAS, I was convinced that this proc was a new 'super' Proc SQL running only on CAS server. Well it is not really the case but this proc has some advantages. In this tips and tricks we will first make a summary of the most important things discussed in the introduction SAS Viya for SAS users tips and tricks. Then we will dive into the PROC FEDSQL in CAS with topics such as:

  • Use PROC SQL to load data to CAS
  • PROC FEDSQL is not specific to CAS
  • Run FEDSQL in CAS
  • Why should I use proc FEDSQL.
  • Use FEDSQL to query ANSI SQL3 tables
  • Use FEDSQL to combine tables of different source

Then we will discuss couple of differences compared with PROC SQL:
  • SESSREF, memnemonic and libname
  • NO REMERGE, NO CALCULATED, NO NUMBER
  • Add format and label
  • Create macro with into clause
  • Use insert into

This tips and tricks is also interesting when you start with SAS programming with SAS Viya or if you plan to do a migration from SAS9 to SAS Viya.

Prerequisites

You have some SAS experience in SAS 9 and are familiar with PROC SQL. Moreover, you already followed the introduction SAS Viya for SAS users tips and tricks.


Go back to your selection


This site uses cookies. .

By continuing to browse the site you are agreeing to our use of cookies. Review our cookies information for more details.