Top Method Summary
Options Name Purpose
AddBestCandidate (character, character, dataset) Determines the best matching pair of indexes of the given parent and child temp-table and creates a ttDataRelationCandidate record for it
CHARACTER BuildRelationFields (character, integer) Builds the RelationFields value (the field pairs) for the given index field names
BuildWorkIndexes (dataset) Builds the working index temp-table for all temp-tables of the design
GetDataRelationCandidates (character, dataset, table, table) Returns the possible data-relations for a temp-table that has been added to the Business Entity design
CHARACTER MapSourceIndexFields (character, character, dataset) Maps the database field names of a source index to the field names of the temp-table
INTEGER MatchingLeadingFields (character, character, character, character, dataset) Returns the number of leading index fields of the child index that are matched by the fields of the parent index

Top Property Summary
Options Name Purpose
INTEGER RankChildIndexPrimary
INTEGER RankChildIndexUnique
INTEGER RankDesignIndex
INTEGER RankParentIndexPrimary
INTEGER RankParentIndexUnique
INTEGER RankPerField
INTEGER SourceIndexOrderOffset


Method Detail
Top

AddBestCandidate (character, character, dataset)

Purpose: Determines the best matching pair of indexes of the given parent
and child temp-table and creates a ttDataRelationCandidate record
for it
Notes: Operates on the working index temp-table built by BuildWorkIndexes.
When no pair of indexes matches, no record is created

Parameters:
pcParentTempTableName CHARACTER
The name of the parent (source) temp-table
pcChildTempTableName CHARACTER
The name of the child temp-table
dsBusinessEntity DATASET dsBusinessEntity
Dataset with the current Business Entity design
Top

CHARACTER BuildRelationFields (character, integer)

Purpose: Builds the RelationFields value (the field pairs) for the given
index field names
Notes: The parent and the child temp-table use the same field names for
the relation, so every field name is repeated once

Parameters:
pcFieldNames CHARACTER
The comma-delimited list of the index field names
piFieldCount INTEGER
The number of leading field names to use
Returns CHARACTER
The comma-delimited list of the relation field pairs
Top

BuildWorkIndexes (dataset)

Purpose: Builds the working index temp-table for all temp-tables of the
design
Notes: The indexes of the temp-table design are added first, followed by
the indexes of the source database tables whose field names could
be mapped to temp-table fields. A source index whose name is
already part of the design is skipped. Word indexes are ignored,
they cannot back a data-relation

Parameters:
dsBusinessEntity DATASET dsBusinessEntity
Dataset with the current Business Entity design
Top

GetDataRelationCandidates (character, dataset, table, table)

Purpose: Returns the possible data-relations for a temp-table that has
been added to the Business Entity design
Notes: The new temp-table is always the child of the suggested
data-relation, the existing temp-tables of the design are the
candidates for the parent (source) table

Parameters:
pcChildTempTableName CHARACTER
The name of the temp-table that has been added to the design
dsBusinessEntity DATASET dsBusinessEntity
Dataset with the current Business Entity design
ttDataRelationSourceIndex TEMP-TABLE ttDataRelationSourceIndex
Temp-Table with the indexes of the source database tables, may be empty
ttDataRelationCandidate TEMP-TABLE ttDataRelationCandidate
Output Temp-Table with one row per possible source temp-table
Top

CHARACTER MapSourceIndexFields (character, character, dataset)

Purpose: Maps the database field names of a source index to the field
names of the temp-table
Notes: The fields are matched through the FieldSource of the eField
records (the source buffer name of the temp-table plus the
database field name), with the plain field name as the fallback.
The mapping stops at the first field that is not part of the
temp-table - the leading fields are still usable as relation
fields

Parameters:
pcTempTableName CHARACTER
The name of the temp-table
pcFieldNames CHARACTER
The comma-delimited list of the database index field names
dsBusinessEntity DATASET dsBusinessEntity
Dataset with the current Business Entity design
Returns CHARACTER
The comma-delimited list of the temp-table field names, blank when no field could be mapped
Top

INTEGER MatchingLeadingFields (character, character, character, character, dataset)

Purpose: Returns the number of leading index fields of the child index that
are matched by the fields of the parent index
Notes: The parent index fields must be the leading fields of the child
index, the field names must be equal and the fields must have the
same data type in both temp-tables. Returns 0 when the two indexes
do not match

Parameters:
pcParentIndexFields CHARACTER
The comma-delimited list of the parent index field names
pcChildIndexFields CHARACTER
The comma-delimited list of the child index field names
pcParentTempTableName CHARACTER
The name of the parent (source) temp-table
pcChildTempTableName CHARACTER
The name of the child temp-table
dsBusinessEntity DATASET dsBusinessEntity
Dataset with the current Business Entity design
Returns INTEGER
The number of matching leading index fields, 0 when the indexes do not match


Property Detail
Top

INTEGER RankChildIndexPrimary


Returns INTEGER
Top

INTEGER RankChildIndexUnique


Returns INTEGER
Top

INTEGER RankDesignIndex


Returns INTEGER
Top

INTEGER RankParentIndexPrimary


Returns INTEGER
Top

INTEGER RankParentIndexUnique


Returns INTEGER
Top

INTEGER RankPerField


Returns INTEGER
Top

INTEGER SourceIndexOrderOffset


Returns INTEGER


ProDataset Detail

ProDataset dsBusinessEntity

Member tables: eBusinessEntity, eDataRelation, eDataRelationProperties, eTable, eField, eFieldProperties, eIndex, eIndexProperties, eTableProperties, eBusinessEntityProperties


Temp-Table Detail

Temp-Table eBusinessEntity

Defined in:

Temp-Table eBusinessEntityProperties

Defined in:

Temp-Table eDataRelation

Defined in:

Temp-Table eDataRelationProperties

Defined in:

Temp-Table eField

Defined in:

Temp-Table eFieldProperties

Defined in:

Temp-Table eIndex

Defined in:

Temp-Table eIndexProperties

Defined in:

Temp-Table eTable

Defined in:

Temp-Table eTableProperties

Defined in:

Temp-Table ttDataRelationCandidate

Defined in:

Temp-Table ttDataRelationSourceIndex

Defined in:


©2006-2026 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       16.08.2026 16:55:09