RELATION()

From Lianjapedia
Revision as of 11:11, 7 December 2009 by Helengeorge (Talk)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Purpose

Function to return table-linking expression


Syntax

RELATION(<expN>)


See Also

TARGET(), DBRELATION(), SET RELATION, CREATE VIEW, CREATE BRIDGE, SET VIEW, USE, DBRSELECT()


Description

The RELATION() function is synonymous with the DBRELATION() function. The RELATION() function returns the linking expression of a specified relation in the current workarea. The <expN> specifies the position of the desired linking expression from the list of previously defined relations. By default, the Recital environment supports 20 workareas but this can be increased, by setting the environment symbol DB_MAXWKA to a higher value, which allows for up to (DB_MAXWKA-1) relationships. The RELATION() function always returns a character string in lower case. If there is no linking expression defined for the <expN> selected, a null string will be returned.


Example

use shows in 2 index pcode
use patrons in 1
set relation to patron_code into shows
? relation(1)
patron_code
? target(1)
         2


Products

Recital, Recital Server