Creating the Order Detail Table
You will now create the Order Detail Table for the Order Entry sample application.
-
Click the Create New Table button on the Table Explorer toolbar.
In the Create New Table dialog, typeOrderDetailas the Table Name and click Ok.
The new table will open in the Table Editor. -
Add columns to the table schema until your column definitions look like those in the image below.
Next, you will add an index for this table.
- Click on the Add Index toolbar button on the Index tab to add a new index. The segments of this index will be
Order_NumberandDetail_Number.
The completed index should look like this:
Next, you will add relationships for this table.
-
Click on the Add Relationship toolbar button on the Relationships tab to add a new relationship.
This will open the Add a Relationship dialog.
Select the OrderHead table and click Ok. -
In the relationship Column Pairs grid, select
Order_Numberin the From OrderDetail column andOrder_Numberin the To OrderHead column.
The completed relationship should look like this:

-
Click on the Add Relationship toolbar button on the Relationships tab to add a new relationship.
This will open the Add a Relationship dialog.
Select the Invt table and click Ok. -
In the relationship Column Pairs grid, select
Item_Idin the From OrderDetail column andItem_Idin the To Invt column.
The completed relationship should look like this:

- Click the Save File toolbar button (or press
Ctrl + S) to save the table schema.
The Output window will display the results of the save operation.
Note that a Data Dictionary is automatically created when you create a new table (when you save the table the first time).
At this point, you have created all the database tables for the Order Entry application.