The Query Wizard JOIN Step

The JOIN step applies to charting and reporting (Sum, Average, etc.) data sources. Chart  Chart data sources may have one or two JOIN steps.  (Two JOIN steps are enabled when the chart is located in a table panel’s repeating row.)  Joins connect (join) tables used by the data source and are manifested as INNER JOIN statements in the underlying SQL query.  For example, if a chart shows the “SUM of Order Details.UnitPrice” for each ShipCountry in an Orders table, it is necessary to join the Order Details and Orders tables.  Joins are not needed when both the ‘sums and counts’ function and the index field belong to the same table.

Iron Speed Designer offers joins based on foreign key relationships.  If tables do not have foreign key relationships they could not be joined using the Query Wizard.  You may need to add a virtual foreign key to use the Query Wizard in this case.  The Query Wizard as well as the Charting Wizard and Sums and Counts Wizard allow you to create self joins, i.e., joining a table to itself if the table has a foreign key field pointing to its own primary key field.  (For example in the Southwind database, the Employees.ReportsTo field points to the Employees.EmployeeID field.).

A second JOIN step is enabled only when a chart is located in a table’s repeater row and it is needed to join the repeater’s table to the chart’s table.  It can be joined to any table included in the join path in the first step.  Iron Speed Designer automatically pre-selects shortest possible join path which you can modify if necessary.

See Also

Customizing Database Queries with the Query Wizard

The Query Wizard JOIN Step

The Query Wizard SELECT Step

The Query Wizard TOP Step

The Query Wizard WHERE Step

The Query Wizard ORDER BY Step

The Query Wizard FINISH Step