What is a relationship between tables?

Relationship are used to join different tables together base on key fields. Relationship can be between one to one table or one to many tables. 

NOTE: To use the Build export function to add relationships between tables in an export. The export needs to have been created by a template or by the Build export function. This will not work for any export that has be build using Custom SQLs

Adding a Relationship

Once you have added tables and selected fields within those tables for the export, relationships between the tables must be specified.

  1. Select the Options button at the top of the command screen
  2. From the drop down menu select Relationships.
  3. When the table relationships screen is displayed, select Add.
  4. Once the add button has been selected the Relationship Edit screen is shown. This is where the relationship between tables must be specified.
    NOTE: The alias name is used if a field name is the same in more than one table.
  5. The relationship join Type is also determined here.
    1. Inner Join: Only include records where the joining fields are equal, 
    2. Left Outer: Include all records from the 'left' table and any matching records from the 'right'
    3. Right Outer: Include all records from the 'right' table and any matching records from the 'left' 
  6. Click on Save
  7. Once the relationship has been saved it will be shown as follows in the Table relationship screen. The Join Type shown will depend upon which option was chosen when defining the Type 
  8. If there are more tables selected in this command the relationships between those table can also be added.
  9. Once all of the relationships have been defined click on the Close button
  10. Under the Export Command Summary section you can see how many relationships have been added. Click on the link to access them.