data outputData;
set work.example;
*this is very important;
by contrato_id;
*last variable in the by statement indicates a new group;
if last.var and nro_cuota_plan < cuotas_plan then do ;
output;
do i=nro_cuota_plan+1 to cuotas_plan;
nro_cuota_plan+1;
output;
end;
end;
else output;
run;
... View more
Hi! Attached is an example, the column "cuotas_plan" the total number of payments. The column Nro_Cuota_Plan are the number of payments I see, in the first case there are 12 payments and I see only 3. Thanks!!
... View more
The original dataset have the number of rows of the number of payments till the basedate. I need to have rows equal de number of payments . In the example attached there are 18 payments but only 16 rows, so I need to add two more rows. The number of rows added will depend of the total number of payments and the maximun payment I see.
... View more
Hi! We need to add rows in a sas dataset, the number of rows depends on the difference between two columns and is variable according to an id. Attached is an example in excel, in yellow are the rows needed to be add. Thanks!!!
... View more