7
1 Applying SAS Parallel- Processing Feature Berwick Chan, [email protected] Kaiser Permanente Vaccine Study Center NCAL Division of Research For BASAS May 2014 meeting

Applying SAS Parallel-Processing Feature

Embed Size (px)

DESCRIPTION

Applying SAS Parallel-Processing Feature. Berwick Chan, [email protected] Kaiser Permanente Vaccine Study Center NCAL Division of Research For BASAS May 2014 meeting. SAS Step-by-Step Sequential Processing Flow. Execution Time. SAS starts. Task 1. X seconds. Task 2. y seconds. - PowerPoint PPT Presentation

Citation preview

Page 1: Applying SAS Parallel-Processing Feature

1

Applying SAS Parallel-Processing Feature

Berwick Chan, [email protected] Permanente Vaccine Study CenterNCAL Division of Research

For BASAS May 2014 meeting

Page 2: Applying SAS Parallel-Processing Feature

2

SAS Step-by-Step Sequential Processing Flow

SAS starts

Task 1

Task 2

SAS ends

Execution Time

X seconds

y seconds

Total: (x+y) seconds

Applying SAS Paralle Processing Feature - B. Chan

Page 3: Applying SAS Parallel-Processing Feature

3

SAS Parallel Processing Flow

SAS starts

SAS ends

SAS starts SAS starts

Task 1

SAS ends

SAS ends

Execution Time

Task 2

Task1 Task 2

x sec

y sec

Total exec time: max(x,y) sec

Applying SAS Paralle Processing Feature - B. Chan

Page 4: Applying SAS Parallel-Processing Feature

4

Ideal Tasks For Parallel Processing

¨ Independent tasks that run on the same server. For example, sorting 2+ huge SAS tables

¨ Independent tasks that run on different servers. For example, reading Oracle/DB2/Teradata tables simultaneously

¨ Linking standalone SAS programs together with a set of user-defined condition. (Production job setting)

Applying SAS Paralle Processing Feature - B. Chan

Page 5: Applying SAS Parallel-Processing Feature

5

SAS Code Samples

¨ Basic MP-Connect program structure

¨ Sorting two tables concurrently

¨ Sending two passthru sql to different servers concurrently

mp_readdb.sas.txt

mp_template.sas.txt

mp_sort.sas.txt mp_sort_unix.log.txt

Applying SAS Paralle Processing Feature - B. Chan

mp_sort.log.txt

Page 6: Applying SAS Parallel-Processing Feature

6

More SAS Code SamplesLinking/Running independent SAS programs with controls such as:¨ Be able to communicate among independent

programs¨ Be able to check status of individual program¨ Be able to define logic to determine program flow

on the fly, for example, if anyone of the independent programs yields non zero return code then abort the entire program

mp_prod1.sas.txt mp_prod1.log.txt cats.sas.txt

Applying SAS Paralle Processing Feature - B. Chan

Page 7: Applying SAS Parallel-Processing Feature

7

More About MP-Connect

¨ Useful links:http://support.sas.com/onlinedoc/913/getDoc/en/connref.hlp/connrefwhatsnew900.htm

http://support.sas.com/rnd/scalability/tricks/connect.html

http://www2.sas.com/proceedings/sugi28/279-28.pdf

Applying SAS Paralle Processing Feature - B. Chan