Figure 1, Feb97 Test Drive

:listf testfile,2
ACCOUNT=CC      GROUP=PUB


FILENAME        CODE            LOGICAL RECORD          SPACE
                SIZE    TYP     EOF     LIMIT   R/B     SECTORS #X      MX
TESTFILE                126B    FA      262752  262752  32      129328  4
        25


:run suprtool.pub.robelle


>input testfile                 <----- specify the input file
>use suprtest                   <----- execute a pre-defined set of
commands


def invoice-date,9,4,double    \
def type,25,1,byte              \
def type-account,26,1,byte       \
def job-id,27,8,byte              \
def account-id,35,8,byte           \
def customer-name,43,12,byte             <----- define fields in input file
def payment-date,59,4,double       /
def check-no,63,4,double          /
def paid-amount,71,4,double      /
def invoice-no,99,12,byte       /
item paid-amount,DECIMAL,2     /


>if type="P" and payment-date>=96306 and &    <-----
select a subset of data
>payment-date<=96335 and check-no <> 0
>sort payment-date,desc            <----- specify sort parameters
>extract invoice-date,payment-date,&
>customer-name,job-id,check-no,invoice-no,paid-amount   <---determine
the content and field order of output
>output testsd,link                <----- specify SD output file
>xeq                               <----- execute the commands


Starting input phase.
5% In=11904     Delta-Sec=1.    Wall-Sec=1.     Cpu-Sec=1.
10% In=25344    Delta-Sec=1.    Wall-Sec=2.     Cpu-Sec=1.
        <-snip->
95% In=248448   Delta-Sec=1.    Wall-Sec=20.    Cpu-Sec=15.
100% In=262752  Delta-Sec=1.    Wall-Sec=21.    Cpu-Sec=15.
Starting sort phase.
Starting output phase.
 50% Out=1008   Delta-Sec=0.    Wall-Sec=21.    Cpu-Sec=16.
100% Out=1947   Delta-Sec=0.    Wall-Sec=21.    Cpu-Sec=16.
IN=262752, OUT=1947. CPU-Sec=16. Wall-Sec=21.


>export input testsd <----- pass SD file to STExport
$export output testxtrt <----- use all the defaults
$export exit    <----- create the export file


In=1947. Out=1947. CPU-Sec=2. Wall-Sec=2.
>e
END OF PROGRAM


:type testxtrt|MORE      <----- display example records
96227,96334,"HMT
INC","22530800",14091,"MO348P-01",11463.90
96227,96334,"HMT
INC","22530800",14091,"MO348P-01",924.29
96235,96334,"BRANDYWINE
G","GL",14081,"49768",135.00
96234,96334,"BRANDYWINE
G","GL",14081,"5-3155",155.85
96234,96334,"CORROSION","40730000",14084,"006018",
7500.00

Back to main TestDrive article
Copyright 1997, The 3000 NewsWire. All rights reserved.