Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- SIx Driver RDD v3.00 - Reference Guide - <b>display:</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
  DISPLAY:

  Syntax:

  DISPLAY <exp list> [TO PRINTER] [TO FILE <xcFile>] 
          [<scope>] [WHILE <lCondition>] [FOR <lCondition>] 
          [OFF] [NOOPTIMIZE]

  <exp list> is the list of values to display for each record processed.

  TO PRINTER echoes output to the printer.

  TO FILE echoes output to <xcFile> which can be specified either as a
  literal filename or as a character expression enclosed in parentheses.
  If an extension is not specified, (.txt) is added.

  <scope> is the portion of the current database file to DISPLAY. The
  default is the current record, or NEXT 1.  If a condition is specified,
  the scope becomes ALL.  Mach SIx will only optimize a scope of ALL.

  WHILE <lCondition> specifies the set of records meeting the condition
  from the current record until the condition fails.  Mach SIx does not
  support the WHILE scope.

  FOR <lCondition> specifies the conditional set of records to DISPLAY
  within the given scope.  Mach SIx will optimize any FOR condition that
  contains one or more active index keys.

  OFF suppresses the display of the record number.

  NOOPTIMIZE, preempts optimization and forces default Clipper processing.

  Description:

  DISPLAY is a database command that sequentially accesses records in the
  current work area sending the results of the <exp list> to the console
  in a tabular format with each column separated by a space.  The command
  does not display column headers or pause at pre-determined intervals.
  DISPLAY is identical to LIST with the exception that its default scope
  is NEXT 1 rather than ALL.

  When invoked, output is sent to the screen and optionally to the printer
  and/or a file.  To suppress output to the screen while printing or echoing
  output to a file, SET CONSOLE OFF before the DISPLAY command-line.

  The DISPLAY command may be optimized by specifying one or more active index
  keys in the FOR condition.  Note that Mach SIx will only optimize a DISPLAY
  with a FOR condition and a scope of ALL.  WHILE conditions and alternate
  scopes cannot be optimized by Mach SIx.

  Notes:

  Interrupting output: The Clipper guide suggests using a test for INKEY() in
  the FOR condition in order to interrupt the display processing.  Because of
  the way Mach SIx parses and evaluates the FOR condition this technique is
  not recommended and might produce unexpected results.

  Printer margin: Since DISPLAY is a console command, it honors the current
  SET MARGIN for output echoed to the printer.

  ---------------------------------| EXAMPLE |--------------------------------
  /*:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  *  Demonstrates an optimized DISPLAY command                              *
  *::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::*/

  #include "SIXCDX.CH"
  #include "MACHSIX.CH"

  USE Account VIA "SIXCDX"  // Structural index ACCOUNT.CDX opened
                            // automatically
  CLEAR SCREEN
  ? "Example of an optimized DISPLAY command."
  ?

  // Fully optimized display of records for accounts in Florida.
  // Optimized using STATE index.
  DISPLAY AcctNo, Last, First, Balance FOR State = "FL"
  CLOSE ALL


See Also: LIST

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson