Date: Wed, 24 Aug 2011 14:10:43 -0700
Reply-To: "Terjeson, Mark" <Mterjeson@RUSSELL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Terjeson, Mark" <Mterjeson@RUSSELL.COM>
Subject: Re: step stats
In-Reply-To: <DCCDE0D83A1D0E43BB7001C29ED5B5CA06304267@EX10MAIL2.westat.com>
Content-Type: text/plain; charset="us-ascii"
Hi Michael,
Thanks for the note. Yeah, I also wrote a checklog(logparse)
macro back in July of 1998. Back when I was in the state govt
environment, long SAS programs were prevalent to many
programmers. Occasionally, users could go to lunch while
a long running program ran or come back the next day and
of course after a 10,000 line log had already scrolled by
and only the bottom few lines are showing in the log window.
On occasion, even though users peruse their log, then could
and would miss one or two, and we got bit having to track
back if we were lucky enough to have found out if a problem
went unattended. So I wrote mine to help folks, specifically
to reprint all the ERROR and WARNING lines at the bottom of
the log window so the after lunch or the next morning, they
were proactively prompted to catch all the errors since it
now was reprinted at the bottom of the log window. It helped
a lot. We augmented the checklog macro to include a metadatabase
to be able to accept or rule-out certain messages if desired.
I posted my checklog on SAS-L at one point in time. I am
glad we both have gotten mileage out it them. :o)
As for today's question which I was already pretty sure it
was a "no" answer, you can read my feedback why I was asking
in the other post back to Ron.
Again, thanks for the good ideas,
Mark
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Michael Raithel
Sent: Wednesday, August 24, 2011 1:05 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: step stats
Dear SAS-L-ers,
Mark posted the following:
> Hi All,
>
> A person could certainly use PRINTTO and redirect the log out
> and read it back in, to parse the datastep or proc stimer stats
> for "real time" or "cpu time" for each step back into the SAS
> program for use.
>
> However, are there any system variables or undocumented
> variables that make stimer values available within a program
> that could be used in subsequent steps?
>
Mark, unfortunately, the answer is: nope:-( The closest that one can come to a SAS-variable-oriented solution is to use the LOGPARSE SAS macros:
Programmatically Measure SAS Application Performance on Any Computer Platform with the New LOGPARSE SAS Macro.
http://www2.sas.com/proceedings/sugi30/219-30.pdf
One would think that, since SAS has this information available at the end of each DATA step/PROC step, SAS could save it into system variables--kind of like how SAS saves _ERROR_ and such like. You would think...
Mark, best of luck in all your SAS endeavors!
I hope that this suggestion proves helpful now, and in the future!
Of course, all of these opinions and insights are my own, and do not reflect those of my organization or my associates. All SAS code and/or methodologies specified in this posting are for illustrative purposes only and no warranty is stated or implied as to their accuracy or applicability. People deciding to use information in this posting do so at their own risk.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Michael A. Raithel
"The man who wrote the book on performance"
E-mail: MichaelRaithel@westat.com
SAS Press Author Page: http://support.sas.com/publishing/authors/raithel.html
Author: Tuning SAS Applications in the MVS Environment
Author: Tuning SAS Applications in the OS/390 and z/OS Environments, Second Edition
http://www.sas.com/apps/pubscat/bookdetails.jsp?catid=1&pc=58172
Author: The Complete Guide to SAS Indexes
http://www.sas.com/apps/pubscat/bookdetails.jsp?catid=1&pc=60409
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
If an elderly but distinguished scientist says that something
is possible, he is almost certainly right; but if he says that
it is impossible, he is very probably wrong. - Arthur C. Clarke
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++