The SAS Output Delivery System and reporting techniques

I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem started

Reply
New Contributor
Posts: 3

I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem started

Hi,I am trying to work out on listings.

 

after the use of ods listing,the data which is written in editor is not execuint,it simply printing the same in log file,

Guys please let me know why,when and how it happens.

and how to solve the issue.

I'ts not working even to print the sashelp.class data also;

 

 

ods listing close;
ods pdf file ="C:\Users\raj\Desktop\report5\report5.1.pdf";
proc report data=MAIN_PR nowd headline headskip;
title1 " Listing 16.2.4.5";
title2 " Virology (ADVATE Only Subjects)";
title3 " ";
title4 " ";
title5 " ";
title6 " ";
title7 " ";
title8 "Study Group: PTP <then PUP>" ;

COLUMN ("--" SBJID EX_BL_C1 TEST POSITVE_TIME TH_CON );


define SBJID/order 'Subject ID' width=8 ;
define EX_BL_C1/DISPLAY'EXPOSURE OF BLOOD COMPONENT' width=6;
define TEST/DISPLAY 'TEST RESULT' width=20 ;
define POSITVE_TIME/DISPLAY 'FIRST POSITVE TIME' width=10;
define TH_CON/DISPLAY 'Whether Therapy is Conducted?' width=8;


break after SBJID/skip;
compute after;
line @5 '________________________________________________________________________________________________________';
line 20*'__';
line'';
line @5'Abbreviations:' ;
line @5'PTP=previously treated population; PUP=previously untreated ';
line @5'population.';

 

endcomp;
run;
ods pdf close;
ods listing close;

 

/****************

proc print data=sashelp.class;

run;

*********************/

 

The same it is printing  in the log file without generating the output

Super User
Posts: 8,216

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

Could it be that your final

ods listing close;

just before the proc print, should have been:

ods listing;

Art, CEO, AnalystFinder.com

 

Super User
Posts: 24,010

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

There’s likely something that messed it up, unbalanced quotes or incorrectly terminated line. 

 

Try restarting your session and re-running the code to see if the issue persists. Check a different piece of code before you run the code that you think is causing the issue. 

 

If it persists you likely have an issue with your code. Look at the colours to see if something isn’t coloured correctly as a starting point. 

Super User
Posts: 13,941

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta


geethak wrote:

Hi,I am trying to work out on listings.

 

after the use of ods listing,the data which is written in editor is not execuint,it simply printing the same in log file,

Guys please let me know why,when and how it happens.

and how to solve the issue.

I'ts not working even to print the sashelp.class data also;

  

The same it is printing  in the log file without generating the output


You do not show the line you are getting from the log. If it looks like:

WARNING: No output destinations active.

Then the cause is you are requesting output, such as from Proc Print or Proc Report but you have Closed all of the ODS Destinations and likely @art297's response is the answer.
 

 

New Contributor
Posts: 3

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

Yeah, I am getting that issue also.

Please tell me how to resolve or get back out of it..
Super User
Posts: 8,216

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

run the line:

ods listing;

As I mentioned, before, toward the end of your code you close the ods listing

 

Art, CEO, AnalystFinder.com

 

New Contributor
Posts: 3

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

I tried, but it doesn’t worked for me.
Again the whole code is printing in the log file.
Super User
Posts: 24,010

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta

1. Did you restart SAS?
2. In a fresh session, what happens when you submit the following, please post the full log:

 

proc print data=sashelp.class;
run;
Super User
Posts: 13,941

Re: I am trying to work out on listings,suddenly when i used ods concept ,then the exact problem sta


geethak wrote:
Yeah, I am getting that issue also.

Please tell me how to resolve or get back out of it..

 

with the no destinations warning you have to open at least one of the ODS destinations before requesting any output to either the Listing or results window.

 

Ods LIsting;

proc print data=sashelp.class;

run;

or

Ods  html;

proc print data=sashelp.class;

run;

 

or even send to a file such as with ODS RTF or ODS PDF.

 

 

Show your log with the code submitted from your ODS destination statement to through the warnings, notes or errors after the proc print or report. Paste into a code box opened with the forum {I} menu icon to preserver formatting from the log as some of the diagnostics are position dependent and the main message windows will reformat the text.

Ask a Question
Discussion stats
  • 8 replies
  • 179 views
  • 0 likes
  • 4 in conversation