User`s guide
Tables can be linked in a report as long as the following criteria are met:
• The link fields are both database fields.
• The link fields contain similar data.
• The link fields are the same length.
• The link field in the link to (lookup) table is indexed (PC databases only).
Linking tables is rarely a problem. However, there are some circumstances in which you cannot
coordinate data from different tables because the data does not meet the linking criteria.
For example, linking to or from a formula field, or linking two unindexed tables cannot be done in a
single report. Subreports must be used.
22.6.1 Linking to/from a formula field
There are situations in which you may need to link to or from a formula (calculated) field. For example,
an employee ID could be an 11 character value that consists of a two-character department code
followed by the employee's nine-character Social Security Number (for example, HR555347487).
The formula language makes it easy to extract the Social Security Number from this field:
{employee.EMPLOYEE ID} [-9 to -1]
- or -
{employee.EMPLOYEE ID} [3 to 12]
For the value HR555347487, either formula would return the value 555347487.
While the return value is a valid Social Security Number, the fact that it comes from a formula prevents
you from using the field to link to a Social Security Number field in another table. You can report on
and coordinate the values in the two tables, however, by using a subreport.
22.6.1.1 To link to/from a formula field
1.
Create the primary report using a table that includes the Social Security Number field.
2.
Create (or import) a subreport using the formula that extracts the Social Security Number from the
Employee ID field (for this example, {@EXTRACT}).
See Inserting subreports.
3.
Place the subreport where you want it to appear in the primary report.
2012-03-14499
Subreports