DATA Step, Macro, Functions and more

Recursive data step reference

Reply
Contributor
Posts: 50

Recursive data step reference

[ Edited ]

HI all 

 

I have a situation where I have to read from sas dataset A and create dataset B and next time in the do loop I have to read it from Dataset B and so on ! How can I achieve this?

 

Thanks for all the help!

 

J

Trusted Advisor
Posts: 1,115

Re: sas datastep

Hi @SASSLICK001,

 

Can you please provide more details on your question, e.g., sample data (in the form of a data step) together with the intended result and existing SAS code (or pseudocode) of the algorithm you have in mind? For example, is the DO loop a macro %DO loop?

Super User
Posts: 10,483

Re: sas datastep

It is also quite likely if your additional datasteps are only calculating new variables and such that they could all be done in one datastep.

Respected Advisor
Posts: 4,644

Re: Recursive data step reference

Maybe proc datasets command AGE could be useful here

 

proc datasets lib=myLib nolist;

age B A OLD_A OLDER_A;

run;

PG
Ask a Question
Discussion stats
  • 3 replies
  • 302 views
  • 2 likes
  • 4 in conversation