@Reeza This is the full log: 1 The SAS System 14:17 Thursday, November 22, 2018
1 ;*';*";*/;quit;run;
2 OPTIONS PAGENO=MIN;
3 %LET SYSLAST=WORK.TRANSP_EFE;
4 %LET _CLIENTTASKLABEL='Program1';
5 %LET _CLIENTPROJECTPATH='C:\Users\U\Documents\SASEG_SOLEMPRESARIALES\ProjectLOGS.egp';
6 %LET _CLIENTPROJECTNAME='ProjectLOGS.egp';
7 %LET _SASPROGRAMFILE=;
8
9 ODS _ALL_ CLOSE;
10 OPTIONS DEV=ACTIVEX;
11 GOPTIONS XPIXELS=0 YPIXELS=0;
12 FILENAME EGSR TEMP;
13 ODS tagsets.sasreport13(ID=EGSR) FILE=EGSR
14 STYLE=HtmlBlue
15 STYLESHEET=(URL="file:///C:/Program%20Files/SASHome/SASEnterpriseGuide/6.1/Styles/HtmlBlue.css")
16 NOGTITLE
17 NOGFOOTNOTE
18 GPATH=&sasworklocation
19 ENCODING=UTF8
20 options(rolap="on")
21 ;
NOTE: Writing TAGSETS.SASREPORT13(EGSR) Body file: EGSR
22
23 GOPTIONS ACCESSIBLE;
24 %macro condition;
25
26 proc printto log="/sasdata/u_Data/log.log" new;
27 run;
28
29 filename mylog1 "/sasdata/u_Data/log.log";
30
31 PROC SQL;
32 CREATE TABLE SUMMARY AS
33 SELECT FECHA,
34 CIF,
35 T1.'CLIENTES SEGUN ICBS'N,
36 FROM WORK.TRANSP_EFE T1;
37 QUIT;
38
39 %put &syserr;
40
41 proc printto log=log;
42 run;
43
44 data _null_;
45 infile mylog1 ;
46 input;
47 put _infile_;
48 run;
49
50
51 %if &syserr > 0 %then %do;
52
53 filename mylog "/sasdata/u_Data/log.log"; /* <=== Specify your SAS log location here. */
54
55 filename report "/sasdata/u_Data/reportlog.txt" ; /* <=== Specify the location for your report here. */
56
57
2 The SAS System 14:17 Thursday, November 22, 2018
58 data _null_;
59
60
61 infile mylog;
62 input;
63
64 lineno+1; /* Increment Line Number */
65
66 file report;
67
68 rec = _infile_;
69
70 /* Check for ERROR: type error message */
71
72 foundit = index(rec,"ERROR:");
74 if ( foundit > 0 ) then do;
75
76 put lineno " " rec;
77 end;
78
79 /* Check for ERROR 99-999: type error message */
81 foundit = index(rec,"ERROR ");
83 if ( foundit > 0 ) then do;
84
85 rec=substr(rec,foundit);
86
87 if length(rec) > 15 then do;
88
89 tempstr=substr(rec,1,15);
90
91 if (substr(tempstr,7,1) >= "0" and substr(tempstr,7,1) <= "9"
92 and index(tempstr,"-") > 0 and index(tempstr,":") > 0 ) then do;
93
94 put lineno " " rec;
95 end;
96 end;
97 end;
98
99 /* Check for WARNING: type warning message */
100
101 foundit = index(rec,"WARNING:");
103 if ( foundit > 0 ) then do;
104
105 put lineno " " rec;
106 end;
107
108 /* Check for WARNING 99-999: type error message */
110 foundit = index(rec,"WARNING ");
112 if ( foundit > 0 ) then do;
113
114 rec=substr(rec,foundit);
115
116 if length(rec) > 15 then do;
117
118 tempstr=substr(rec,1,15);
119
120 if (substr(tempstr,9,1) >= "0" and substr(tempstr,9,1) <= "9"
121 and index(tempstr,"-") > 0 and index(tempstr,":") > 0 ) then do;
3 The SAS System 14:17 Thursday, November 22, 2018
122
123 put lineno " " rec;
124 end;
125 end;
126 end;
127
128 /* Check for "ERROR [" type warning message */
129
130 foundit = index(rec,"ERROR [");
132 if ( foundit > 0 ) then do;
133
134 put lineno " " rec;
135 end;
136
137 /* Check for "WARN [" type warning message */
138
139 foundit = index(rec,"WARN [");
141 if ( foundit > 0 ) then do;
142
143 put lineno " " rec;
144 end;
145
146 filename outbox email attach=("/sasdata/u_Data/reportlog.txt")
147
148 to=''
149
150 type='text/html'
151 subject= "Log ETL"
152 from='';
153
161
162 run;
163 run;
164
165 %end;
166 %mend;
167 %condition;
NOTE: PROCEDURE PRINTTO used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds
NOTE: The infile MYLOG1 is:
Filename=/sasdata/u24807_Data/log.log,
Owner Name=U40621,Group Name=sas,
Access Permission=rw-rw-r--,
Last Modified=Thu Nov 22 16:51:02 2018,
File Size (bytes)=1181
NOTE: PROCEDURE PRINTTO used (Total process time):
real time 0.00 seconds
cpu time 0.01 seconds
22: LINE and COLUMN cannot be determined.
NOTE 242-205: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred.
ERROR 22-322: Syntax error, expecting one of the following: !, !!, &, (, *, **, +, ',', -, /, <, <=, <>, =, >, >=, ?, AND, BETWEEN,
CONTAINS, EQ, EQT, FROM, GE, GET, GT, GTT, LE, LET, LIKE, LT, LTT, NE, NET, OR, ^=, |, ||, ~=.
79: LINE and COLUMN cannot be determined.
NOTE: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred.
ERROR 79-322: Expecting a FROM.
NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements.
4 The SAS System 14:17 Thursday, November 22, 201
8
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE SQL used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds
1012
NOTE: 24 records were read from the infile MYLOG1.
The minimum record length was 0.
The maximum record length was 133.
NOTE: DATA statement used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds
168
169
170
171
172
173 GOPTIONS NOACCESSIBLE;
5 The SAS System 14:17 Thursday, November 22, 2018
174 %LET _CLIENTTASKLABEL=;
175 %LET _CLIENTPROJECTPATH=;
176 %LET _CLIENTPROJECTNAME=;
177 %LET _SASPROGRAMFILE=;
178
179 ;*';*";*/;quit;run;
180 ODS _ALL_ CLOSE;
181
182
183 QUIT; RUN;
184 syserr value is 1012
... View more