6. Using JoinDefs in QBF : How You Create a JoinDef
 
Share this page                  
How You Create a JoinDef
Creating a JoinDef requires specifying the tables, the common join columns, the update and delete rules, and the columns to be displayed.
The following steps describe the general process of creating, testing, and saving a JoinDef. (The steps and frames are all discussed in more detail later in this chapter.)
1. Choose JoinDefs from either the Ingres Menu or from the QBF Startup frame.
2. Choose Create from the JoinDefs Catalog frame.
The Creating a JoinDef pop-up form appears.
3. Place the cursor on one of the available options and choose the Select operation:
Blank (to create a JoinDef from a blank frame)
Duplicate (to base a JoinDef on an existing JoinDef definition)
If you are basing the new JoinDef on an existing one, the Creating a JoinDef by Duplication pop-up form appears. (See the following figure.) Proceed to Step 4.
If you are creating a JoinDef from a blank frame, the JoinDefs Catalog frame appears. Proceed to Step 5.
4. Enter the name of the existing JoinDef on the Creating a JoinDef by Duplication pop-up form and choose the Select operation.
If you do not know the name of the existing JoinDef, select the ListChoices operation to display a list of the available choices.
5. When the JoinDefs Catalog frame appears, choose the Create operation.
See JoinDefs Catalog Frame (see page JoinDefs Catalog Frame) and JoinDef Definition Frame (see page JoinDef Definition Frame).
6. Type the JoinDef name in the space following JoinDef Name and press Return.
Perform the next three steps for each table you want to join. Use Tab and the arrow keys to move from column to column and row to row as needed.
7. Type the kind of table it is (Master or Detail) in the Role column. If none of the tables has a Master/Detail relationship to each other, enter them all as Master tables even if some or all of them are Detail tables on other JoinDefs. Enter as a Detail table any table that has a detail relationship (many records to one record) to any master table.
8. Type the table name in the Table Name column.
If you do not know the table name, use the ListChoices operation to display a list of the available tables.
9. Type an optional abbreviation for the table name in the Abbreviation column.
10. Type n (no) in the Table Field Format field if you want to view all your data in simple-fields format.
The default is to display the data in table-field form.
11. Choose Joins to display the JoinDef Join Specification frame. If QBF has automatically established join columns to join the tables, they are displayed. If necessary, enter or change the join specifications. For more information, see How Columns Are Joined (see page How Columns Are Joined).
12. Return to the JoinDef Definition frame and save your JoinDef by selecting the End operation.
Before or after you save your JoinDef, you can perform either or both of the optional enhancements listed below.