%macro utr(i,bnk_inp);
/****************Cond2*************************/
%if &UTRNAM =0 and &bennam > 0 %then %do;
DATA rr.UTR_&i(drop=BENE_ACK rename=(BENE_ACK_=BENE_ACK));
SET rr.utr_&i;
%if %substr(BENE_ACK,1,2)="00" %then BENE_ACK_=%substr(BENE_ACK,3);
%else BENE_ACK_=BENE_ACK;
run;
proc sql;
create table rr.first_&i as
select *,(a.narration=b."MBOL REFERENCE NO"n) as indic ,
(a.narration ~= "")as step1,
(b."MBOL REFERENCE NO"n ne "") as utr,
coalesce( a.narration ,b."MBOL REFERENCE NO"n) as fid
from rr.&bnk_inp a full join rr.UTR_&i b on compress(a.narration)=compress(b."MBOL REFERENCE NO"n);
quit;
data rr.ref_match_&i;
set rr.first_&i;
where ((indic =1 and step1=1 ) or ( indic=1 and step1=0 and utr=0 and fid= " "));
run;
proc sql;
create table rr.narration_ref_mismatch_&i as
select * from rr.&bnk_inp where compress(narration) not in ( select narration from rr.ref_match_&i );
quit;
proc sql;
create table rr.sec_c2_&i as
select *,(a.narration=b.bene_ack) as indic ,
(a.narration ne "")as step1,
(b.bene_ack ne "") as utr,
coalesce( a.narration ,b.bene_ack) as fid
from rr.narration_ref_mismatch_&i a full join rr.utr_&i b on a.narration=b.bene_ack;
quit;
data rr.ben_match_&i;
set rr.sec_c2_&i;
where (indic =1 and step1=1);
run;
proc sql;
create table rr.overall_mismatch_&i as
select *,"mismatch" as flag from rr.narration_ref_mismatch_&i where compress(narration) not in ( select narration from rr.ben_match_&i );
quit;
%end;
%mend;
%macro uu;
%IF IF &II > 0 AND &FF > 0 %THEN %UTR(1,step1_) and %UTR(2,overall_mismatch_1);
%mend;
%uu;
Here i am trying to invoke a same macro twice .But i am facing the following error in the log
180: LINE and COLUMN cannot be determined.
NOTE: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred.
ERROR 180-322: Statement is not valid or it is used out of proper order.
NOTE: Line generated by the invoked macro "UTR".
88 DATA rr.UTR_&i(drop=BENE_ACK rename=(BENE_ACK_=BENE_ACK)); SET rr.utr_&i;
___
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
NOTE: Line generated by the invoked macro "UTR".
88 BENE_ACK_=BENE_ACK
_________
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
NOTE: Table RR.FIRST_2 created, with 115063 rows and 74 columns.