Creating a Join With Graphical Tools

How to:

Reference:

The Join tool provides a graphical method for creating and manipulating Joins. You must specify a host file, then a cross-referenced file to create a join.

You create the Join as an object, separate from any other object or procedure. You are responsible for placing the Join object in the correct position within your procedure (that is, before a Define, Report, or Graph), and for running it. The Join remains active for the entire session, unless you explicitly clear it.

You can open the Join tool from either the toolbar or from a reporting tool. Before the tool opens, you will be asked to select a host file.

The Join tool displays both files and, ordinarily, a default Join, as shown in the following image.


Top of page

x
Reference: Join Toolbar

When you access the Join tool, a toolbar opens below the title bar. You can access the following commands from the toolbar:

Button

Command

Description

Save

Save

Saves the join.

New Join

New Join

Creates additional concurrent joins.

Note: You may also select New Join from the right-click context menu in the Join window.

Add File

Add File

Selects a cross-referenced file to join to the host file you have already selected.

Note: You may also select Add File from the right-click context menu in the Join window.

Clear Join

Clear Join

Launches the Join Clear window.

Note: You may also select Clear Join from the right-click context menu in the Join window.

Run Join

Runs a join to check syntax.

Note: You may also select Run from the right-click context menu in the Join window.

Delete

Deletes a selected object (table or join).

Define Field

Define Field

Launches the Define dialog box to create a virtual field in the host file.

Create/Edit Selection

Create/Edit Selection

Launches the WHERE Expression Builder to create WHERE criteria and change the join type to a conditional join. This is enabled only when the host table is selected.

Show/Hide Source Code

Show/Hide Source Code

Shows or hides the FOCUS code generated by the Join tool. This is enabled only when the Join link is selected.

Toggle Auto Join

Toggle Auto Join

Performs automatic joins within tables.

Cascade

Cascade

Creates a cascade view of multiple joins (default).

Horizontal Tile

Horizontal Tile

Splits the Join tool horizontally when working with multiple joins.

Vertical Tile

Vertical Tile

Splits the Join tool vertically when working with multiple joins.



x
Procedure: How to Create a Join

If you want to define a Join in a procedure:

  1. Right-click the procedure and choose Edit in Developer Studio Tool from the context menu.

    The Procedure Viewer opens.

  2. Click the component connector (yellow diamond) at the point where you want to include the join in the procedure, then click the Join button on the component connector toolbar.
  3. Choose a Master File for the data source you wish to use as your host file and click Open.

    The Join tool opens showing a Fields window for the host file that you selected.

  4. To add a cross-referenced data source to the Join, click the Add File button on the Join toolbar or choose File from the Developer Studio Insert menu.

    Tip: You may also right-click anywhere in the Join window and select Add File from the context menu.

  5. Select a cross-referenced file.
  6. Click OK.

    A default Join is created if the host and cross-referenced files share appropriate fields. If a default Join is not created, follow the instructions in Customizing a Join to create your own.


Top of page

x
Procedure: How to Create a Join for a Reporting Object in Developer Studio

Note: This procedure applies to creating a Join in the Managed Reporting environment.

  1. In the Reporting Object window, double-click Join.

    The WebFOCUS Table List dialog box opens.

  2. Choose a Master File for the data source you wish to use as your host file, and click OK.

    The Join tool opens showing a Fields window for the host file that you selected.

  3. To add a cross-referenced data source to the Join, click the Add File button.

    The WebFOCUS Table List opens again.

  4. Select a cross-referenced file.
  5. Click OK.

    A default Join is created if the host and cross-referenced files share appropriate fields. If a default Join is not created, follow the instructions in Customizing a Join to create your own.


Top of page

x
Procedure: How to Create a Left Outer Join With the Join Tool in Developer Studio
  1. To open the Join Properties dialog box, do one of the following:
    • In the Join tool, right-click a join link and select Left Outer Join.

      or

    • In the Explorer, right-click a join link and select Properties.

      or

    • Double-click a join link in the Explorer.

    The Join Properties dialog box opens.

  2. Select the Left Outer Join option button.
  3. Click OK.

Top of page

x
Procedure: How to Add Information About Fields to Join Field Lists

The Field list for each data source being joined displays the field names by default. To help you build meaningful joins you can add information about the listed fields.

  1. With the Join tool open, right-click within a table to view available field options. To change information displayed for tables globally, select Options from the Window menu. Click the Reporting tab and select the appropriate options from the Field List Options area.
  2. Select any or all of the following items: Qualified Names, Show Name, Show Alias, Show Title, Show Description, Show Format. A check mark displays next to your selections. Name and Descriptions are checked by default.

    The selected information categories appear as headings in the field list for each joined file. Details will appear if the corresponding information is included in the Master File.

  3. Expand the window to see the additional field list columns. Click the column titles if you want to change the sort order.

WebFOCUS