Date: Wed, 21 Mar 2001 16:04:55 +0100
Reply-To: Peter Crawford <peter.crawford@DB.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Peter Crawford <peter.crawford@DB.COM>
Subject: opinion: SAS or macro debugging: mprint or macrogen+symbolgen
Content-type: text/plain; charset=iso-8859-1
Perhaps this feature is available "off-mainframe" but I have yet to find it.
(hint = I need a nice viewer/editor on aix)
In the ISPF services on TSO in os390, the VIEW option provides an
extremely easy reviewing/debugging of a full saslog and manages
the mixture of debugging aids with selective "hiding" which is
referred to as the "eXcluding lines feature"
It is so useful a feature, I have been disappointed that SI have
yet to support it ( first ballot requested in pgm-ed in 1988 ).
This feature in VIEW is like "collapsing" steps in the enhanced
editor, but is simpler, and allows more !
The "eXcluded lines feature" allows lines to be selected for
exclusion using command X(for eXclude) like command F(ind).
So, save that fat (full of symbolgen/source/source2/mlogic/mprint)
saslog into a file, then in tso/ispf, just VIEW the file and
issue commands like
command ===>
x 'SYMBOLGEN: ' all; x 'mlogic(' all
to hide those lines. Blocks of the (temporarily) unwanted lines reduce to
one. Even those "eXcluded" lines can be removed with
command ===>
delete all x
The advantage of VIEW over EDIT surfaces here - when you close
VIEW, it does not save these deletes automatically (like EDIT would)
So it might be nicer if SAS Institute changed the default behaviour of the
hostedit command (hed) in a LOG window to use the VIEW command
instead of the BROWSE command as at present.
(there are other useful features of this edit/view environment which
are not provided in display manager's editors......
but this thread is about recommendations for handling debug info...
Regards
Peter Crawford
Datum: 21/03/2001 14:34
An: SAS-L@listserv.uga.edu
Antwort an: rjf2@cdc.gov
Betreff: opinion: SAS or macro debugging: mprint or macrogen+symbolgen
Nachrichtentext:
yesterday I helped
Aldi Kraja [mailto:aldi@WUBIOS.WUSTL.EDU]
debug some SAS statements.
The log that he initially presented was generated with:
options nomprint macrogen symbolgen;
This led me to consider that his problem was in the macro statements which
included several loops.
While I think I correctly pointed out that his macro %put statements should
have been SAS put statements, the macrogen+symbolgen log obfuscated my
ability to connect the error message with the appropriate incorrect SAS
statement.
As soon as he supplied a log using:
options mprint nomacrogen nosymbolgen;
the error message appeared in relation to the offending SAS statement.
In summary:
when debugging SAS statements generated by macros, use:
options mprint;
when debugging macro statements including logic and especially do-loop
counters then
options macrogen symbolgen;
is appropriate.
Critique is invited and encouraged.
Ron Fehd the macro maven CDC Atlanta GA USA RJF2@cdc.gov
---> cheerful provider of in-my-not-so-humble opinion !*! <---
By using your intelligence you can sometimes make your problems twice as
complicated.
-- Ashleigh Brilliant
By using your intelligence you can sometimes make my error detection twice
as complicated.
-- RJF2
--
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist nicht gestattet.
This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.