BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Bluedog
Calcite | Level 5

I thought the %stpbegin controled the ods.  When I do a simple gplot, the graph is generated fine.  But when I do a proc print, nothing is generated. I get the msg:

WARNING: No output destinations active.

1 ACCEPTED SOLUTION

Accepted Solutions
Bluedog
Calcite | Level 5

Problem solved.  The "Stream" check box on the Execution panel of the Metadata registration in SMC needed to be checked.  I don't know why, but it does.

View solution in original post

3 REPLIES 3
Cynthia_sas
SAS Super FREQ

Hi:

  Not enough information. You said "when you do a proc print" - -but where -- in the same stored process with the gplot? In a new stored process? What is your client application (Word, Excel, EG, Web Report Studio, Info Delivery Portal, Stored Process Web App,) that is submitting the stored process? You are correct that the %stpbegin goes at the top of your stored process code and begins the capture of ODS output. (If all you had in your program was a PROC SORT, for example, nothing "visible" would be produced by PROC SORT -- but if you correctly have PROC PRINT between
%stpbegin/and %stpdend, then you should see output.) The %stpend goes at the end of your stored process and closes all open destinations. One thing that could possibly be interfering with %stpbegin/%stpend would be an:

ods _all_ close;  <--this might be placed incorrectly before the proc print -- should not have this in the code at all

or

%stpend;   <--- this might be placed incorrectly before the proc print (should be placed AFTER proc print)

...or other "exclusionary" statements (like ODS EXCLUDE ALL or ODS SELECT NONE) might be buried in your code someplace. Also, failing to use proper step boundaries (such as RUN; or QUIT;) can prevent results from being generated. But usually, the no output destinations active message comes from prematurely closing all the open destinations.

  So without more information (such as seeing more of your code, and how you are requesting the SP to run, knowing how you are registering the stored process in the metadata -- what server, what type of results, etc), it's hard to give more concrete suggestions.

  You can also open a track with Tech Support on this issue -- they could look at all of your code, at your metadata and collect all the information they need to help you come to a resolution.

cynthia

Bluedog
Calcite | Level 5

The code:

%global device sdate edate _odsdest;

*ProcessBody;

data _null_;

    d1="&sdate";

   d2="&edate";

   ds=input(d1,date11.);

   de=input(d2,date11.);

   call symput('start',ds);

   call symput('end',de);

data ip;

    set pricea.nc_cs_upgrd_201205_n(keep=device device_type equip_inst_eff_dt acct_type prior_device prior_device_type  where=(device=:"&device" and acct_type=:'U'));

    upgds=1;

    if &start le equip_inst_eff_dt le &end;

proc sort;

    by equip_inst_eff_dt device prior_device_type prior_device;

proc means sum noprint;

    output out=sums(drop=_type_ _freq_) sum=;

    var upgds;

    by equip_inst_eff_dt device prior_device_type prior_device;

%STPBEGIN; 

proc print;

TITLE1 "From Upgrades for &device";

FOOTNOTE ;

RUN;

%STPEND;

Bluedog
Calcite | Level 5

Problem solved.  The "Stream" check box on the Execution panel of the Metadata registration in SMC needed to be checked.  I don't know why, but it does.

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 1502 views
  • 0 likes
  • 2 in conversation