SiMX Help‎ > ‎The Target Platform‎ > ‎Objects‎ > ‎DS (Data Source)‎ > ‎


Common Objects


Returns a relation object, which defines relations between the two tables, which identifiers are passed in as parameters.

Note: Use of aliases to identify the tables rather than table names is recommended.


Function GetRelation( left, right )


string left    - the left table identified by an alias or table name
string right - the right table identified by alias or table name

Return Values

object - the relationship between left and right


Dim rel
Set rel = DS.GetRelation( "Accounts", "Items" )

rel.definition = "Accounts.AccountID=Items.AccountID"

Note: Because the return value is an object, using the keyword Set is mandatory in VBScript.

See also