UTIL.SQR
This utility has 2 main functions: a formatter to "beautify"
a program, and a "trace" function which creates a version of your program
which sends out a message at the beginning of each procedure. (I find it
useful when I want to quickly pinpoint which "select" is bogging down a
large report).
If you use the formatting function, beware of the following
problems:
- it doesn't handle tabs well when it tries to fix up your "if" statements.
- if you have columns selected in "if" clauses, it will move the columns
and the program will fail on compile.
i.e.:
begin-select
if $run='3'
mgr <- this column will be positioned in the "if" clause
end-if
from EMP
end-select
- Sometimes it indents "if" statements 3 spaces, sometimes "4". I wrote
this program late at night while waiting for a relative to arrive at the
airport, and never got around to fixing this bug.
Still, it almost always works. It creates a new file called new.sqr, so you
can easily see what it did.
History:
- The 99/8/18 version shows the time for each procedure run (for the
trace option).
Contributed by Chanan Morrison, chananm@netvision.net.il.
Download UTIL.SQR.
Send comments and questions to the
SQRUG Librarian.
Go to SQR Users Group Home Page.
File last modified 20-DEC-1997.