Hello, i have to read db tables when
1) db table is fully loaded for a day (loading time is very in between specific time, lets say 1 am to 3 am) then i do some processing
2) at end of the process, i have to export 3 sas dataset into 3 different text file and once this export is done - i want to create 3 file (lets say simple empty text file without any data) which says okay, data files are out there and ready - so that other process (not SAS from now on) can read that empty file and further processing can happen - how to output empty file (touch file) once export is done,
Thanks.
%macro test;
data _null_; set sashelp.stocks; call symput ("nofobs", _n_); run;
%put &nofobs;
%if &nofobs. >= 1 and Date = '1Aug2003'd %then %do;
data test; set sashelp.stocks; run;
/*output text files*/ proc export data=test outfile='some share drive\datafile1.txt' dbms=tab replace; putnames=no; run;
proc export data=test2 outfile='some share drive\datafile2.txt' dbms=tab replace; putnames=no; run;
proc export data=test3 outfile='some share drive\datafile3.txt' dbms=tab replace; putnames=no; run;
/*once those three text file done, want to touch empty 3 file */ /*some logic */
filename mymail email "email" subject="sas data ready alert ";
data _null_; file mymail; put "Hello team,"; put "SAS output is avilable, plese use data and process further"; run;
%end;
%else %do;
filename mymail email "email" subject="oracle table alert";
data _null_; file mymail; put "Hello team,"; put "Table doesn't have enough records, sas is not going to process the table"; run;
%end;
%mend;
%test;
... View more