<?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: Searching log for errors and warnings in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507886#M1535</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;All of the above translates into "there's no easy way to do this search for errors and warnings in Base SAS".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The fact that Enterprise Guide and SAS/Studio make this easy doesn't help in Base SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RegEx&amp;nbsp;doesn't help in the LOG window, there is no way to do a RegEx on the text in the LOG window. (yes you could read the LOG into the&amp;nbsp;Enhanced Editor window and then use RegEx there but that doesn't constitute easy to me).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And the last suggestion by&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt;&amp;nbsp;seems to be the closest, but there's no way to save this search, everytime you do it you have to do a Ctrl-F and then type the word ERROR and turn on the proper search options.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Actually, at least in my install of SAS 9.4&amp;nbsp;for Windows 10 , the Find dialog for the LOG window will retain the last settings such as "match case" or "whole word" and defaults to the last searched term, at least within a session.&lt;/P&gt;</description>
    <pubDate>Fri, 26 Oct 2018 20:06:36 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2018-10-26T20:06:36Z</dc:date>
    <item>
      <title>Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507799#M1515</link>
      <description>&lt;P&gt;Do errors and warnings&amp;nbsp;ALWAYS&amp;nbsp;appear in the log as "ERROR:.." and "WARNING:..."? If so, then instead scrolling through the log (which can be long is many cases), can't you simply&amp;nbsp;search (i.e., find) the log&amp;nbsp;for&amp;nbsp;&lt;SPAN&gt;ERROR:.." and "WARNING:..."?&amp;nbsp;&lt;/SPAN&gt; &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 16:04:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507799#M1515</guid>
      <dc:creator>rfitler</dc:creator>
      <dc:date>2018-10-26T16:04:52Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507802#M1516</link>
      <description>&lt;P&gt;There are some errors that have numbers between the word error and :&lt;/P&gt;
&lt;P&gt;ERROR 180-123:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But they always start in column 1 of the log and you can make an RegEX to search but you will have to lookup the meta characters.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 16:13:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507802#M1516</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2018-10-26T16:13:08Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507805#M1518</link>
      <description>&lt;P&gt;In SAS EG you can view the&lt;STRONG&gt; Log Summary &lt;/STRONG&gt;Go to&lt;STRONG&gt; View&amp;gt;Log Summary&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="image.png" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/24414i992B2E5B25932D9E/image-size/large?v=v2&amp;amp;px=999" role="button" title="image.png" alt="image.png" /&gt;&lt;/span&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can write the log into a file using PROC PRINTTO and then scan that file for any errors or warnings or etc, for this there are several papers out there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/resources/papers/proceedings12/042-2012.pdf" target="_blank"&gt;http://support.sas.com/resources/papers/proceedings12/042-2012.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.lexjansen.com/pharmasug/2008/cc/CC02.pdf" target="_blank"&gt;https://www.lexjansen.com/pharmasug/2008/cc/CC02.pdf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 16:18:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507805#M1518</guid>
      <dc:creator>SuryaKiran</dc:creator>
      <dc:date>2018-10-26T16:18:52Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507809#M1520</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/165141"&gt;@rfitler&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Do errors and warnings&amp;nbsp;ALWAYS&amp;nbsp;appear in the log as "ERROR:.." and "WARNING:..."? If so, then instead scrolling through the log (which can be long is many cases), can't you simply&amp;nbsp;search (i.e., find) the log&amp;nbsp;for&amp;nbsp;&lt;SPAN&gt;ERROR:.." and "WARNING:..."?&amp;nbsp;&lt;/SPAN&gt; &amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Depends somewhat on which version of SAS you are using as tools for the Log are a tad different. The foundation or base SAS Log you could restrict the search to ERROR plus the "match whole word" and "match case" options.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 16:23:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507809#M1520</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-10-26T16:23:16Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507822#M1523</link>
      <description>&lt;P&gt;All of the above translates into "there's no easy way to do this search for errors and warnings in Base SAS".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The fact that Enterprise Guide and SAS/Studio make this easy doesn't help in Base SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RegEx&amp;nbsp;doesn't help in the LOG window, there is no way to do a RegEx on the text in the LOG window. (yes you could read the LOG into the&amp;nbsp;Enhanced Editor window and then use RegEx there but that doesn't constitute easy to me).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And the last suggestion by&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt;&amp;nbsp;seems to be the closest, but there's no way to save this search, everytime you do it you have to do a Ctrl-F and then type the word ERROR and turn on the proper search options.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 16:56:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507822#M1523</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2018-10-26T16:56:30Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507836#M1527</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/165141"&gt;@rfitler&lt;/a&gt;&amp;nbsp;and welcome to the SAS Support Communities!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As you can see from the papers mentioned by&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/83078"&gt;@SuryaKiran&lt;/a&gt;, searching for "ERROR" and "WARNING" is only a very basic log check and sophisticated macros have been developed to refine these checks substantially in order to meet industrial quality standards.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In addition to the occasionally missing colon after "ERROR"&amp;nbsp; (as mentioned by&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/15410"&gt;@data_null__&lt;/a&gt;) there are rare cases where an error message looks different, e.g., once I saw this on a Linux server:&lt;/P&gt;
&lt;PRE&gt;Segmentation Violation In Task [ DATASTEP ]&lt;/PRE&gt;
&lt;P&gt;followed by a number of Linux path names and hex codes, but also the note&lt;/P&gt;
&lt;PRE&gt;NOTE: The SAS System stopped processing this step because of errors.&lt;/PRE&gt;
&lt;P&gt;So, the keyword "error" was at least there.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here is a (hopefully) reproducible example where an error occurs, but only NOTEs are written to the log (again one containing the word "errors", though):&lt;/P&gt;
&lt;PRE&gt;1    data _null_;
2    length text $256;
3    infile log;
NOTE: The file LOG cannot be opened for UPDATE processing.
4    input text;
5    run;

NOTE: The SAS System stopped processing this step because of errors.
NOTE: DATA statement used (Total process time):
      real time           0.01 seconds
      cpu time            0.01 seconds&lt;/PRE&gt;
&lt;P&gt;But the more difficult problem is the large number of possible NOTEs (without "errors") indicating that something went wrong (e.g. division by zero). Also that number is&amp;nbsp;growing (e.g. when new procedures are introduced) and I don't know where to find a &lt;EM&gt;complete&lt;/EM&gt; list in the documentation. I remember to have seen an approach where people put together a &lt;EM&gt;positive list&lt;/EM&gt; of acceptable log messages (rather than a negative list of not acceptable ones) and used this in their log checker. (Not sure how successful that was.)&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 17:20:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507836#M1527</guid>
      <dc:creator>FreelanceReinh</dc:creator>
      <dc:date>2018-10-26T17:20:46Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507886#M1535</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;All of the above translates into "there's no easy way to do this search for errors and warnings in Base SAS".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The fact that Enterprise Guide and SAS/Studio make this easy doesn't help in Base SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;RegEx&amp;nbsp;doesn't help in the LOG window, there is no way to do a RegEx on the text in the LOG window. (yes you could read the LOG into the&amp;nbsp;Enhanced Editor window and then use RegEx there but that doesn't constitute easy to me).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;And the last suggestion by&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt;&amp;nbsp;seems to be the closest, but there's no way to save this search, everytime you do it you have to do a Ctrl-F and then type the word ERROR and turn on the proper search options.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Actually, at least in my install of SAS 9.4&amp;nbsp;for Windows 10 , the Find dialog for the LOG window will retain the last settings such as "match case" or "whole word" and defaults to the last searched term, at least within a session.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2018 20:06:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507886#M1535</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-10-26T20:06:36Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507973#M1564</link>
      <description>&lt;P&gt;Yes,&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt; mine does too, but you still have to re-type and select the settings again in a new SAS session. It would be nice if this could be saved and then called up via a single keystroke, I know there are text editors out there where you can do this.&lt;/P&gt;</description>
      <pubDate>Sat, 27 Oct 2018 11:09:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/507973#M1564</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2018-10-27T11:09:06Z</dc:date>
    </item>
    <item>
      <title>Re: Searching log for errors and warnings</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/508387#M1654</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Yes,&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884"&gt;@ballardw&lt;/a&gt; mine does too, but you still have to re-type and select the settings again in a new SAS session. It would be nice if this could be saved and then called up via a single keystroke, I know there are text editors out there where you can do this.&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Very much agree. And it can't be that hard as the Enhanced Editor Search and Replace does this, well at least it keeps the last x find and replaces available in drop downs, but the settings for whole word, case or regular expression are kept.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Oct 2018 15:39:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Searching-log-for-errors-and-warnings/m-p/508387#M1654</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-10-29T15:39:38Z</dc:date>
    </item>
  </channel>
</rss>

