SAS and UNIX: Rerunning your batches in a smarter way Yaroslav - - PowerPoint PPT Presentation

sas and unix rerunning your batches in a smarter way
SMART_READER_LITE
LIVE PREVIEW

SAS and UNIX: Rerunning your batches in a smarter way Yaroslav - - PowerPoint PPT Presentation

SAS and UNIX: Rerunning your batches in a smarter way Yaroslav Haiovyi, Intego Group, Kharkiv, Ukraine Frankfurt 2018 Three ways to run batches Batch n __________________________ __________________________ __________________________


slide-1
SLIDE 1

SAS and UNIX: Rerunning your batches in a smarter way

Frankfurt 2018

Yaroslav Haiovyi, Intego Group, Kharkiv, Ukraine

slide-2
SLIDE 2

Page 2

Batch №n

__________________________

Manual

__________________________

“runbatch” file

X "sas ad_asl.sas" X "sas qc_ad_asl.sas" X "sas ad_aefga.sas" X "sas qc_ad_aefga.sas" ...........................

__________________________

“makefile”

???

Three ways to run batches

slide-3
SLIDE 3

Page 3

Excel file SAS program

SAS program

“Makefile”

Step-by-step solution

slide-4
SLIDE 4

<tab>command1 <tab>……… <tab>commandN

A target is the name of a file that is generated by a program. A prerequisite is a file that is used as an input to create the target. A command is an action that should be run.

target:

prerequisite1 … prerequisiteN

t(target) > t(prerequisite1) ? ……………………….. t(target) > t(prerequisiteN) ?

Page 4

Structure of the “makefile”

slide-5
SLIDE 5

Page 5

Libname_ Path_ sdtm_1 /project1/study1/SDTMFOLDER/ sdtm_2 /project2/study2/SDTMFOLDER/ sdtm ./SDTMFOLDER adam ./ADAMFOLDER

  • utputs

./outputsfolder

Libname_ : contains the name of libraries that are used in SAS program. Path_ : contains the path to the folders where the files are

  • located. Need to be consistent with UNIX command line.

*.XLS input (Libraries)

slide-6
SLIDE 6

Page 6

Libname_ Dataset_ Relations_ Data Relations_ Prog Command_1 Command_QC sdtm DM _empty_ _empty_ _empty_ _empty_ sdtm AE _empty_ _empty_ _empty_ _empty_ sdtm ZA _empty_ _empty_ _empty_ _empty_ adam ASL sdtm.DM ad_asl.sas sas ad_asl.sas sas qc_ad_asl.sas adam AEFGA sdtm.GA adam.ASL ad_aefga.sas sas ad_aefga.sas sas qc_ad_aefga.sas

*.XLS input (Datasets)

slide-7
SLIDE 7

Page 7

Libname_ Output_ Relations_ Data Relations_ Prog Command_1 Command_QC

  • utputs

t_ga.out adam.ASL adam.AEFGA t_ga.sas sas t_ga.sas sas qc_t_ga.sas

  • utputs

l_ae_luc.out ADAM.asl l_ae_luc.sas sas l_ae_luc.sas _empty_

*.XLS input (TLGs)

slide-8
SLIDE 8

Page 8

"RAWs_and_Other" "SDTMs" "ADaMs" “Tables" “Listings" “Graphs" Datasets TLGs

Grouping order

slide-9
SLIDE 9

Page 9

All Groups Datasets TLGs

Libname_ Dataset_ Relations_ Data sdtm DM _empty_ sdtm ZA _empty_ adam ASL sdtm.DM adam AEFGA sdtm.ZA adam.ASL Libname_ Dataset_ Relations_ Data sdtm DM _empty_ sdtm ZA _empty_ adam ASL DELETED adam AEFGA sdtm.ZA adam.ASL

Sorting order

slide-10
SLIDE 10

Page 10

"RAWs_and_Other" "SDTMs" "ADaMs" “Tables" “Listings" “Graphs"

System:

Line-by-line creation

slide-11
SLIDE 11

Page 11

“Chain” order

Data 1 Data 2 Data 3 Data 1 Data 2 Data 3 Data 1

Not “Chain” order

slide-12
SLIDE 12

Choosy Rerun

Page 12

Rerun adam.ASL = Rerun everything ???

SAS program “Makefile” Rename FILE to OLD_FILE Create FILE Compare FILE and OLD_FILE

  • 1. Keep FILE and delete OLD_FILE

OR

  • 2. Delete FILE and rename

OLD_FILE COMMAND is Run “SAS program”

slide-13
SLIDE 13

Yaroslav Haiovyi yaroslav.haiovyi@intego-group.com Kharkiv, Ukraine www.intego-group.com

T H A N K YO U