<?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 Writing ods output to SAS EG results only in ODS and Base Reporting</title>
    <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/744893#M25049</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to create a simple program which would run a git status on a folder and do one of the following:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;if there is nothing to commit, write a line to the result window stating this&lt;/LI&gt;&lt;LI&gt;if there are changes, write that and show what needs to be committed&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;I got most of the way there, but the text gets written to the "path" column. I would like to write it outside of the table:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data _null_;
	length path $255 status $10 staged $5;
	array gitstats path status staged;
	drop files n rc;
	files = git_status("&amp;amp;folder");
	file print ods=(variables=(path status staged));

	if files GT 0 then
		do;
			put "The following changes are present in the directory, please check:";

			do n = 1 to files;
				do over gitstats;
					rc = git_status_get(n, "&amp;amp;folder", vname(gitstats), gitstats);
				end;

				put _ods_;
			end;
		end;
	else put "The folder is clean";
	rc = git_status_free("&amp;amp;folder");
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;How can I achieve this? Thanks for the help in advance.&lt;/P&gt;</description>
    <pubDate>Tue, 01 Jun 2021 09:36:07 GMT</pubDate>
    <dc:creator>js5</dc:creator>
    <dc:date>2021-06-01T09:36:07Z</dc:date>
    <item>
      <title>Writing ods output to SAS EG results only</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/744893#M25049</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am trying to create a simple program which would run a git status on a folder and do one of the following:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;if there is nothing to commit, write a line to the result window stating this&lt;/LI&gt;&lt;LI&gt;if there are changes, write that and show what needs to be committed&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;I got most of the way there, but the text gets written to the "path" column. I would like to write it outside of the table:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data _null_;
	length path $255 status $10 staged $5;
	array gitstats path status staged;
	drop files n rc;
	files = git_status("&amp;amp;folder");
	file print ods=(variables=(path status staged));

	if files GT 0 then
		do;
			put "The following changes are present in the directory, please check:";

			do n = 1 to files;
				do over gitstats;
					rc = git_status_get(n, "&amp;amp;folder", vname(gitstats), gitstats);
				end;

				put _ods_;
			end;
		end;
	else put "The folder is clean";
	rc = git_status_free("&amp;amp;folder");
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;How can I achieve this? Thanks for the help in advance.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jun 2021 09:36:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/744893#M25049</guid>
      <dc:creator>js5</dc:creator>
      <dc:date>2021-06-01T09:36:07Z</dc:date>
    </item>
    <item>
      <title>Re: Writing ods output to SAS EG results only</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/744955#M25055</link>
      <description>&lt;P&gt;Where 'outside of the table'?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Maybe you want a simple FILE PRINT; instead of File ODS.&lt;/P&gt;
&lt;P&gt;However you would have to have a PUT statement for the variables when you want them in the output.&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jun 2021 14:56:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/744955#M25055</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-06-01T14:56:23Z</dc:date>
    </item>
    <item>
      <title>Re: Writing ods output to SAS EG results only</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/745084#M25057</link>
      <description>&lt;P&gt;"Outside of the table" would be a row of text, akin to as if I opened an ods destination and ran ods text/proc odstext before running proc print. File print does work to some extent, but it produces a somewhat ugly monospace text in a frame.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Jun 2021 06:12:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/745084#M25057</guid>
      <dc:creator>js5</dc:creator>
      <dc:date>2021-06-02T06:12:22Z</dc:date>
    </item>
    <item>
      <title>Re: Writing ods output to SAS EG results only</title>
      <link>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/762797#M25254</link>
      <description>&lt;P&gt;Create a macro that will print a message to the result&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%macro printmsg(msg);
data _msg;
  message = "&amp;amp;msg";
run;
proc print data=_msg noobs;
run;
proc delete data=_msg;
run;
%mend;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;change the code where you want to print to the result and use the DOSUBL function, it allows you to execute other steps while in a step like so:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;
data _null_;
	length path $255 status $10 staged $5;
	array gitstats path status staged;
	drop files n rc;
	files = git_status("&amp;amp;folder");
	
	if files GT 0 then
		do;
			put "The following changes are present in the directory, please check:";

			do n = 1 to files;
				do over gitstats;
					rc = git_status_get(n, "&amp;amp;folder", vname(gitstats), gitstats);
				end;
        file print ods=(variables=(path status staged));
				put _ods_;
			end;
		end;
	else do;
    rc = dosubl('%printmsg(The folder is clean)');
  end;
	rc = git_status_free("&amp;amp;folder");
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 20 Aug 2021 09:42:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/ODS-and-Base-Reporting/Writing-ods-output-to-SAS-EG-results-only/m-p/762797#M25254</guid>
      <dc:creator>BrunoMueller</dc:creator>
      <dc:date>2021-08-20T09:42:05Z</dc:date>
    </item>
  </channel>
</rss>

