As the first step in the decommissioning of sasCommunity.org the site has been converted to read-only mode.
Here are some tips for How to share your SAS knowledge with your professional network.
You skip the strip(put()) in the CALL SYMPUT by using CALL SYMPUTX.
Enjoyed your TIP. Keep up the good work.
Charlie Shipp 05:57, 20 January 2010 (UTC)
The code for finding if there are any observation or no observation has the STOP statement missing just before the RUN statement. If a dataset is passed in &data macro variable which has no observation(s) then datastep ends where set statement is finished hence value for anyobs macro variable would be 0 which is correct, but when a dataset is passed in &data macro variable which has atleast 1 observation then step would iterate once again even though obs=1 dataset option is coded and the next iteration would end when set statement is finished as obs=1 is coded hence anyobs macro variable would again be set to 0. In order to get this code to work perfectly, we would need to code STOP statement just before the RUN statement in order to prevent the datastep to iterate once again. Please fix.