<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Directing procedure output to log in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705322#M216336</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I would like to create a nice summary of what macro has done in the SAS log window, so users see exactly what happened. For that reason, I have prepared a dataset and would like to route it to the log window with proc report or other printing procedure.&lt;/P&gt;&lt;P&gt;In batch mode, this can be done with&amp;nbsp;&lt;/P&gt;&lt;P&gt;filename outfile "location of log file";&lt;/P&gt;&lt;P&gt;proc printto file=outfile new;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could this be done in any way also in interactive runs? I wouldn't want to use put statements or anything like that as formatting of information becomes quite difficult. Below please see an example of what I would like to go into the log:&lt;/P&gt;&lt;P&gt;Package&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;Dependency&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dependency type&amp;nbsp; &amp;nbsp; &amp;nbsp;Version&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Download Status&lt;BR /&gt;------------------------------------------------------------------------------------------------------------&lt;BR /&gt;VIM 6.0.0&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Downloaded&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;car&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Depends&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;gt;=1.9.4&amp;nbsp;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;colorspace&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Depends&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;MASS&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Imports&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Marcin&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 11 Dec 2020 16:04:02 GMT</pubDate>
    <dc:creator>MarcinP1980</dc:creator>
    <dc:date>2020-12-11T16:04:02Z</dc:date>
    <item>
      <title>Directing procedure output to log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705322#M216336</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I would like to create a nice summary of what macro has done in the SAS log window, so users see exactly what happened. For that reason, I have prepared a dataset and would like to route it to the log window with proc report or other printing procedure.&lt;/P&gt;&lt;P&gt;In batch mode, this can be done with&amp;nbsp;&lt;/P&gt;&lt;P&gt;filename outfile "location of log file";&lt;/P&gt;&lt;P&gt;proc printto file=outfile new;&lt;BR /&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could this be done in any way also in interactive runs? I wouldn't want to use put statements or anything like that as formatting of information becomes quite difficult. Below please see an example of what I would like to go into the log:&lt;/P&gt;&lt;P&gt;Package&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;Dependency&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Dependency type&amp;nbsp; &amp;nbsp; &amp;nbsp;Version&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Download Status&lt;BR /&gt;------------------------------------------------------------------------------------------------------------&lt;BR /&gt;VIM 6.0.0&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Downloaded&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;car&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Depends&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;gt;=1.9.4&amp;nbsp;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;colorspace&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Depends&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;MASS&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Imports&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Marcin&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 11 Dec 2020 16:04:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705322#M216336</guid>
      <dc:creator>MarcinP1980</dc:creator>
      <dc:date>2020-12-11T16:04:02Z</dc:date>
    </item>
    <item>
      <title>Re: Directing procedure output to log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705331#M216342</link>
      <description>&lt;P&gt;You can use same method while running SAS interactively as when running batch.&lt;/P&gt;
&lt;P&gt;Try it.&lt;/P&gt;</description>
      <pubDate>Fri, 11 Dec 2020 16:34:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705331#M216342</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2020-12-11T16:34:57Z</dc:date>
    </item>
    <item>
      <title>Re: Directing procedure output to log</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705333#M216343</link>
      <description>&lt;P&gt;Just do the same thing. Use a temporary file if you don't need the extra copy.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;filename thisrun temp; 
proc printto print=thisrun new;
run;
proc print data=sashelp.class; run;
proc printto print=print; run;
data _null_;
  infile thisrun;
  input;
  put _infile_;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;PRE&gt;7922  data _null_;
7923    infile thisrun;
7924    input;
7925    put _infile_;
7926  run;

NOTE: The infile THISRUN is:

      Filename=...\#LN00057,
      RECFM=V,LRECL=32767,File Size (bytes)=1113,
      Last Modified=11Dec2020:11:59:24,
      Create Time=11Dec2020:11:59:24

SAS 9.4 on WINDOWS                                                       16:48 Monday, December 7, 2020  77

Obs    Name       Sex    Age    Height    Weight

  1    Alfred      M      14     69.0      112.5
  2    Alice       F      13     56.5       84.0
  3    Barbara     F      13     65.3       98.0
  4    Carol       F      14     62.8      102.5
  5    Henry       M      14     63.5      102.5
  6    James       M      12     57.3       83.0
  7    Jane        F      12     59.8       84.5
  8    Janet       F      15     62.5      112.5
  9    Jeffrey     M      13     62.5       84.0
 10    John        M      12     59.0       99.5
 11    Joyce       F      11     51.3       50.5
 12    Judy        F      14     64.3       90.0
 13    Louise      F      12     56.3       77.0
 14    Mary        F      15     66.5      112.0
 15    Philip      M      16     72.0      150.0
 16    Robert      M      12     64.8      128.0
 17    Ronald      M      15     67.0      133.0
 18    Thomas      M      11     57.5       85.0
 19    William     M      15     66.5      112.0
NOTE: 23 records were read from the infile THISRUN.
      The minimum record length was 0.
      The maximum record length was 107.
NOTE: DATA statement used (Total process time):
      real time           0.06 seconds
      cpu time            0.01 seconds
&lt;/PRE&gt;</description>
      <pubDate>Fri, 11 Dec 2020 17:00:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Directing-procedure-output-to-log/m-p/705333#M216343</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2020-12-11T17:00:41Z</dc:date>
    </item>
  </channel>
</rss>

