TAA Tools

The Display Data  Base File by  Key command displays or  prints records
from  a  single format  data  base file  in  keyed sequence.    The key
fields  appear  as the  first  fields in  the  listing.   Any remaining
fields that fit into the  378 maximum wide print line are  also listed.
DSPDBFKEY is a  front end to the PRTDB key  which allows listing fields
by name.

Use  the  DSPACCPTH  command to  display  the fields  that  make  up an
access path.

A file with a keyed access path must be specified for DSPDBFKEY.

A typical command would be:

             DSPDBFKEY  FILE(xxx)

By default, a display of the  listing would appear.  The key fields  of
the  named file  would  appear on  the  left of  the  listing in  keyed
order.   Any remaining fields in  the file would be  listed after up to
the maximum  width  of 378  bytes.   A  maximum  of 50  fields  may  be

Options exist  to control  the maximum  width of any  field listed  and
the number of records listed.

DSPDBFKEY escape messages you can monitor for

None.  Escape messages from based on functions will be re-sent.

Command parameters                                    *CMD

   FILE          The  qualified name  of  the file  to be  listed.   It
                 must  be  a single  format  keyed file.    The library
                 value  defaults  to *LIBL.    A  specific  library  or
                 *CURLIB may also be used.

   MBR           The member  to be listed.   *FIRST is the default.   A
                 specific member or *LAST may be named.

   MAXFLDWTH     The  maximum  width  of a  field  for  printing.   The
                 default is  99.    This  allows  large  fields  to  be
                 truncated  so you  can  see some  of  the  data.   The
                 value must be in a range of 20 to 99.

   NBRRCDS       The  number  of  records  to  print.    The  parameter
                 defaults  to  *DFT  which  means  that  a  maximum  is
                 assigned depending on  the environment.   If DSPDBFKEY
                 is  used interactively, 1000  records is  the default.
                 If  DSPDBFKEY is  used in  batch, 5000  records is the

                 A specific  number  or *MAX  (99,999 records)  may  be

   OUTPUT        How  to output  the  results.   *  is  the default  to
                 display  the spooled  file if  the command  is entered
                 interactively.  The spooled  file is deleted after  it
                 is displayed.

                 If  the  command is  entered  in  batch or  *PRINT  is
                 specified,  the spooled  file is output  and retained.

   TITLE         The Title of  the report.   The default is  'DSPDBFKEY
                 TAA Tool Output'  Up to 50 characters may  be entered.
                 The title appears on every page of the report.


The file must be keyed.

A maximum of 50 fields may be listed.


The following TAA Tools must be on your system:

     CHKOBJ3         Check object 3
     PRTDB           Print data base file
     RSNLSTMSG       Resend last message
     RTVFLDARR       Retrieve field array
     RTVKEYLST       Retrieve key list
     SNDCOMPMSG      Send completion message
     SNDESCINF       Send escape information
     SNDESCMSG       Send escape message
     SNDLNGMSG       Send long message


None, the tool is ready to use.

Objects used by the tool

   Object        Type    Attribute      Src member    Src file
   ------        ----    ---------      ----------    ----------

   DSPDBFKEY     *CMD                   TAADBLM       QATTCMD
   TAADBLMC      *PGM       CLP         TAADBLMC      QATTCL
   TAADBLMR      *PGM       RPG         TAADBLMR      QATTRPG

Added to TAA Productivity tools June 30, 2007

Home Page Up to Top