I am using the following to read a work dataset that was created right before the data_null step to check to see if any observations exists. When I added the code to my program it turns the next CREATE TABLE' statement red and gives errors.
I cannot figure out what have have wrong with my data step. Any help would be appreciated.
data _null_;
call symput('AnyObs','0'); /* set to 0 for No */
set Work.Finacial_CORP(obs=1);
call symput('AnyObs','1'); /* if got here there are obs so set to 1 for Yes */
run;
CREATE TABLE work.Financial_FRAN AS
SELECT DISTINCT
t1.DISTRICT,
t1.ACCOUNT_TYPE,
t1.ACCOUNT_BEG_DATE,
t1.ACCOUNT_END_DATE,
t1.COUNTY_NAME,
t1.ADDR_LINE_1,
t1.ADDR_LINE_2,
t1.CITY,
t1.STATE,
t1.ZIP,
count(*) FORMAT=comma7. AS FRANRptCnt
FROM WORK.DATA_SELECTED t1
WHERE t1.ACCOUNT_TYPE = 999;
... View more