Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- The Guide To Clipper - <b>dbrelation()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
DBRELATION()


Syntax:     DBRELATION(<expN>)

Purpose:    To determine the linking expression of a specified relation
            in the current work area.

Argument:   <expN> is the ordinal position in the list of relations
            defined in the current work area.

Returns:    A character string.

            DBRELATION() returns a character string containing the
            relation expression of the relation specified by <expN>.  If
            there is no RELATION SET for <expN>, DBRELATION() returns a
            null string ("").

Usage:      DBRELATION() is used in combination with DBRSELECT() to
            query the linking expression and work area of an existing
            relation.  Using these functions in addition to DBFILTER(),
            you can create a user-defined View system analogous to that
            of the Clipper utility, DBU.EXE.  Essentially, you use these
            functions to create the View definition from the
            environment.

Library:    CLIPPER.LIB


----------------------------------- Example --------------------------------

   USE Customer INDEX Customer
   SELECT 2
   USE Invoices INDEX Invoices
   SELECT 3
   USE BackOrder INDEX BackOrder
   SELECT 1
   SET RELATION TO Cust_num INTO Customer;
       TO Cust_num INTO BackOrder
   *
   ? DBRELATION(2)         && Result: Cust_num


See Also: SET RELATION DBFILTER() DBRSELECT()

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