BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
kybowma
Calcite | Level 5

My objective is to identify notes which are not really desired.  Or, maybe they are desired, however I just want to capture them using Perl or some other text parsing language.

 

I was able to find this Surpress SAS Log, however it really focuses on surpress issues, I am more concerned with printing them to the log so that I can capture them.

 

Question, is there a documented list of note messages from SAS which would capture things like:

 

data _null_;
    y=1;
    x=0;
    div=y/x;
    array s{11} (1,0,1,0,1,9,8,7,.25,10,.);
    rate=.25;
    cf=npv(rate,of s{*});
run;

data a b;
    do i='a','a','a','b';
        x=1;
        output a;
    end;
    do i='a','a','b','b';
        y=2;
        output b;
    end;
run;

data _null_;
    merge a b;
    by i;
run;

 

Standard log shows the following: (highlighted is a handful of notes, looking for some sort of full list of notes that would be thrown for performing something "questionable")

 SAS Log Image.JPG

1 ACCEPTED SOLUTION

Accepted Solutions
Astounding
PROC Star

Not a list that I know of, but here are a few you might add to your search:

 

uninitialized, as in "The variable xyz is uninitialized."

 

converted, as in "Character values were converted to numeric at line:number:"

 

missing values, as in "Missing values were generated as a result of ...."

 

You have to decide which ones are worth searching for.  Some shops allow these messages, some don't.

View solution in original post

4 REPLIES 4
Ksharp
Super User

Use function DIVIDE() 

 

 

div=y/x;
-->
div=divide(y,x);
kybowma
Calcite | Level 5

Hi Ksharp!

 

Divide function, yes it would surpress a message such as that.  For the NPV function as well, I could just loop around and check for MISSING() and impute a zero to surpress the mathematical error.

 

However, the programs which I am executing have been written by other users.  The objective here is to find a list of known publishable notes for information such as what was presented in the log.  I posed 3 notes which, is there others???

Astounding
PROC Star

Not a list that I know of, but here are a few you might add to your search:

 

uninitialized, as in "The variable xyz is uninitialized."

 

converted, as in "Character values were converted to numeric at line:number:"

 

missing values, as in "Missing values were generated as a result of ...."

 

You have to decide which ones are worth searching for.  Some shops allow these messages, some don't.

kybowma
Calcite | Level 5

Hi Astounding,

 

Likely there is no formal documentation, I do appreciate the recommendation on some of the others.  I have unitinitiazed covered, but I can add some of the others as well.  Ill add the character to numeric conversion as well as missing values, division by zero and mathematical operations issues and lastlye many to many merges.  

 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 1428 views
  • 0 likes
  • 3 in conversation