<?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 Re: job's post code execution on failure case in SAS Data Management</title>
    <link>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89857#M909</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;a. This job is not creating&amp;nbsp; lib_comm.TBL_COM_ERR_MASTER. It is already created.&lt;BR /&gt;b. &amp;amp;GEN_LOG is a macro global variable and it is also resolved in the job.&lt;BR /&gt;c. Failure occurs before the job.&lt;BR /&gt; &lt;/P&gt;&lt;P&gt;The error is like "this step is stopped" because error occuered before this export.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Dec 2012 05:24:43 GMT</pubDate>
    <dc:creator>Sandhyaa</dc:creator>
    <dc:date>2012-12-05T05:24:43Z</dc:date>
    <item>
      <title>job's post code execution on failure case</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89855#M907</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The following piece of code in the job's post code gets executed when the job's status is success.&lt;/P&gt;&lt;P&gt;Whereas, when the job fails, this code is not getting executed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="text-align: left;"&gt;&lt;STRONG&gt;&lt;SPAN style="font-family: 'Arial','sans-serif'; font-size: 10pt;"&gt;proc export data=lib_comm.TBL_COM_ERR_MASTER&lt;/SPAN&gt; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;SPAN style="font-family: 'Arial','sans-serif'; font-size: 10pt;"&gt;&amp;nbsp;&amp;nbsp; outfile="&amp;amp;gen_log."&lt;/SPAN&gt; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-size: 10pt; font-family: 'Arial','sans-serif';"&gt;&amp;nbsp;&amp;nbsp; dbms=dlm replace; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-size: 10pt; font-family: 'Arial','sans-serif';"&gt;&amp;nbsp;&amp;nbsp; delimiter='|'; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-size: 10pt; font-family: 'Arial','sans-serif';"&gt;run;&lt;/STRONG&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But we could execute a proc sql statement in the job's post code even when the job fails.&lt;/P&gt;&lt;P&gt;Is there are constraints that few statements cannot be executed in the post code when the job fails?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Dec 2012 12:39:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89855#M907</guid>
      <dc:creator>Sandhyaa</dc:creator>
      <dc:date>2012-12-04T12:39:07Z</dc:date>
    </item>
    <item>
      <title>Re: job's post code execution on failure case</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89856#M908</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You haven't given much information about what "failure" means.&amp;nbsp; Did the failed job actually create lib_comm.TBL_COM_ERR_MASTER?&amp;nbsp; Did it actually create the macro variable &amp;amp;GEN_LOG?&amp;nbsp; Did the failure occur in the step just before the PROC EXPORT?&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Dec 2012 15:58:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89856#M908</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2012-12-04T15:58:14Z</dc:date>
    </item>
    <item>
      <title>Re: job's post code execution on failure case</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89857#M909</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;a. This job is not creating&amp;nbsp; lib_comm.TBL_COM_ERR_MASTER. It is already created.&lt;BR /&gt;b. &amp;amp;GEN_LOG is a macro global variable and it is also resolved in the job.&lt;BR /&gt;c. Failure occurs before the job.&lt;BR /&gt; &lt;/P&gt;&lt;P&gt;The error is like "this step is stopped" because error occuered before this export.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Dec 2012 05:24:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89857#M909</guid>
      <dc:creator>Sandhyaa</dc:creator>
      <dc:date>2012-12-05T05:24:43Z</dc:date>
    </item>
    <item>
      <title>Re: job's post code execution on failure case</title>
      <link>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89858#M910</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;OK, that's a good start.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just want to set the bigger picture first.&amp;nbsp; When you use terms like "job" and "step" and "failure" those can vary in meaning depending on the operating system.&amp;nbsp; What is the operating system?&amp;nbsp; Is this all one long SAS job, so that "step" refers to a DATA or PROC step within the same job?&amp;nbsp; Does "failure" mean there was a SAS error message, or does it mean something else?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The solution may be as simple as adding something like this just before the PROC EXPORT:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;options nosyntaxcheck;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You should certainly consider reversing that right after the PROC EXPORT:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;options syntaxcheck;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So here's a possible solution, as well as more questions.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Dec 2012 15:59:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Management/job-s-post-code-execution-on-failure-case/m-p/89858#M910</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2012-12-05T15:59:04Z</dc:date>
    </item>
  </channel>
</rss>

