<?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 SAS Connect - Monitoring Rsubmit program progress in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270367#M53706</link>
    <description>&lt;P&gt;Hi. &amp;nbsp;I'm wondering if you have suggestions for ways to monitor the progress of a Rsubmit SAS Connect Program. Once I submit my program all I see is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOTE: Remote submit to ISASPROD commencing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A good deal of my program is a looping macro that creates a dataset named QueryData and appends it to FinalData. This looping can happen up to 100+ times. &amp;nbsp;Depending on server resources my program can take anywhere from 20 minutes or 8+ hours. &amp;nbsp;I'd like to be able to check in and see how far along the program is. &amp;nbsp;Any suggestions?&lt;/P&gt;</description>
    <pubDate>Fri, 13 May 2016 15:08:42 GMT</pubDate>
    <dc:creator>buechler66</dc:creator>
    <dc:date>2016-05-13T15:08:42Z</dc:date>
    <item>
      <title>SAS Connect - Monitoring Rsubmit program progress</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270367#M53706</link>
      <description>&lt;P&gt;Hi. &amp;nbsp;I'm wondering if you have suggestions for ways to monitor the progress of a Rsubmit SAS Connect Program. Once I submit my program all I see is:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;NOTE: Remote submit to ISASPROD commencing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;A good deal of my program is a looping macro that creates a dataset named QueryData and appends it to FinalData. This looping can happen up to 100+ times. &amp;nbsp;Depending on server resources my program can take anywhere from 20 minutes or 8+ hours. &amp;nbsp;I'd like to be able to check in and see how far along the program is. &amp;nbsp;Any suggestions?&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 15:08:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270367#M53706</guid>
      <dc:creator>buechler66</dc:creator>
      <dc:date>2016-05-13T15:08:42Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Connect - Monitoring Rsubmit program progress</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270373#M53708</link>
      <description>&lt;P&gt;One idea if you have necessary rights is to create a file with the current loop counter.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, with a job taking up to 8 hours, I would suspect&amp;nbsp;that is a candidate for overnight scheduling.&lt;/P&gt;
&lt;P&gt;And, I'm also suspect that you could optimize this job quite a lot. 100+ looping often can be rewritten in a more efficient way (generally speaking, not knowing about your specifics of course).&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 15:28:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270373#M53708</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2016-05-13T15:28:57Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Connect - Monitoring Rsubmit program progress</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270378#M53711</link>
      <description>&lt;P&gt;Hmm..how can I write out a filename? &amp;nbsp;Maybe I could write a filename and append on the &amp;amp;rule_order somehow. &amp;nbsp;Like QueryData_&amp;amp;rule_order perhaps?&lt;BR /&gt;&lt;BR /&gt;Yah, each iteration is a Rule loop. And each record can only be flagged with the first rule's criteria it meets. And the rules are run in order of precedence from 1 to 100+. So if a record qualifies for Rule 1 then it cannot also qualify for Rule 2 on.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;* RULE QUERIES. Build and execute rule queries based on the rules defined in QueryRules (one at a time looping) ;
%macro BuildQueryData(analysis_desc= , rule= , rule_order= );

	proc sql;
	create table QueryData as 
	(       select DISTINCT %str(%')&amp;amp;analysis_desc.%str(%') as RULE_NM length = 58, 
			b.actual_dlvry_date as AD_DT, 
			b.imb_code length = 31, 
			&amp;amp;rule_order as RULE_ORDER,
			b.spm_calc_batch_date
            from iv_ora.bi_spm_piece_recon a,  bids_ora.bi_spm_piece_recon b                                                                                                                                                                                                                                                                                                                                                                                                                                                   
            where a.spm_calc_batch_date = b.spm_calc_batch_date
              and a.imb_code = b.imb_code
            and &amp;amp;rule
	); 
	quit;

	* Append datasets to final dataset ;
	proc append base=FinalData data=QueryData force;
	run;

	* Create unique index (if not exist), to meet the criteria that only one record (imb) per ;
	* rule is kept and counted in the data ;
	data _null_;
		set sashelp.vmember (where=(Libname='WORK' and memname='FINALDATA'));
		if upcase(index) = 'NO' then call execute('%CreateUniqueIndex');
	RUN;

%mend BuildQueryData;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 13 May 2016 15:37:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Connect-Monitoring-Rsubmit-program-progress/m-p/270378#M53711</guid>
      <dc:creator>buechler66</dc:creator>
      <dc:date>2016-05-13T15:37:50Z</dc:date>
    </item>
  </channel>
</rss>

