10-31-2011 12:59 PM
I need help in this code:
%do L = 1 %to &maxid;
%do P = 2 %to &maxid;
create table a&P as
from step&P, step&L
where step&P..LOT eq step&L..LOT and step&P..WF eq step&L..WF;
proc append base=comb1 data=a&P force;
Explanation: MAXID is the macro variable.
Problem: Suppose, the value of maxid is 15.
So for L = 1 - it runs for P = 2 to 15
L = 2 - it runs for P = 2 to 15
L= 3 - it runs for P = 2 to 15.
So, How to increment the value of P every time when we get new value of L??
L = 2 - it should run for P = 3 to 15
L= 3 - it should run for P = 4 to 15.