After creating the business model, the next step is to add the business tables and business columns, then create the relationships between our business tables.
Introducing the Metadata Editor Graph
Up to this point, we have only used the Tree Navigator to construct the business objects. The big white canvas on the right side of the screen is the Metadata Editor Graph, and we use the Graph to lay out our business tables and show the relationships between them. While we can accomplish the rest of our tasks using only use the Tree Navigator, from here forward I will describe how to perform each operation using both the Tree Navigator and the Editor Graph, so you can decide which view suits you better.
Tree Navigator: Creating a New Business Table
To add a new business table using the Tree Navigator, first make sure that the model you want to add this business table to is selected (in the tree), and the Business Tables node is expanded.
- Right-click (or ALT-click) on the Business Tables branch in the Navigator Tree.
- Select the New Business Table... option from the popup menu.
- You will be prompted with a list of physical tables, each prefixed by the connection name they belong to. Select the physical table you want to associate with this new business table.
Under Construction Alert
The first business table you create determines what connection is linked to this model - the one connection that this model can support. The connection is determined by interrogating the physical table that you associate in this step.
We will be building out the connection to business model UI functionality in the future, but realize for now (as of the M4 release) that this area is half-baked. If you change your mind and want to associate a different connection with this model, you will have to delete all of your business tables. You could possibly hand-edit the exported XML and re-import it to change the connection, but I haven't tried it so I won't guarantee that it will work.
- Click OK on the prompt. The Business Table Properties dialog displays.
In the Business Table Properties dialog, you will notice the Name/ID field at the top of the dialog is pre-populated with a value. This is the id of this business table, and MUST be unique. We recommend that you accept the default value for this field.
The table you chose in step 3 is listed next, then below the fields is another Tree Navigator, with the name of your business table and all the columns inherited from the physical table included as business columns. The business columns are created for you when the new business table is created, so no need for the extra steps of creating them separately.
Trimming the Business Columns
To trim unnecessary business columns at this time:
- In the Business Table Properties dialog's Tree Navigator, select a column you wish to remove.
- Click the delete icon (the one with the red circle), to the right of the word Subject above the dialog's Tree Navigator.
- Repeat with any remaining columns that you wish to remove. Click OK when you are done.
Editor Graph: Creating a New Business Table
Creating a business table on the Editor Graph is much like using the Tree Navigator.
- First, you must make sure you have the business model that you want to add this new business table to selected in the Tree Navigator. You can be sure it is selected if you see the name of the model at the top of the Graph canvas.
- Next, right-click on the Graph, and select the New Business Table... option from the popup menu.
Follow the instructions above (for creating the table from the Navigator Tree), starting at step 3.
Shortcut for Creating Business Tables
A nice shortcut! Drag the physical table from the Navigator Tree to the Editor Graph canvas to create a new business table based on that physical table.
Another shortcut is to drag the physical table in the Navigator Tree to the Business Tables node in the tree, which will also create a new business table based on that physical table. NOTE that in the M4 milestone, this shortcut is broken... sorry, soon to be fixed!!