-
Notifications
You must be signed in to change notification settings - Fork 8
Creating Sub Models
Sub-models is used to display selected entities and design your domain-specific database model.
Now, let's take a look on how to create a sub-model.
- Click the Model dropdown and select New.
- On Add Submodel dialog, set the sub-model Name as "MovieActors" and check the Is Draft to specify that this is a draft sub-model and not yet finished.
Note: The Chapter field is used for sorting models. The Is Laboratory checkbox is used to specify that the sub-model is only used for the playground or experiment and not an actual database model.
- You can specify the description/explanation of your sub-model and can use text formatting.
- Select entities that you want to include on the "MovieActors" sub-model. From the list-box on the left, select the "Movie" and "Person" entities and press > button.
- Click OK button to accept the sub-model details.
Oops! Looks like the model board is a mess.
- Right-click on the model board and select Redo Layout to re-arrange the entities.
Voila! 🎉 The entities are now arranged. Next, let's try to add existing entities in this model.
- Right-click on the model board and select Edit Submodel.
- Select the "Genre" entity from the list on the right side and press > button to include it in the MovieActors sub-model and press OK.
- Press the Redo Layout again to re-arrange the entities.
You have added the "Person" entity on the "Social Media" sub-model.
Now, as you've looked at the sub-model, you've realized that "Person" entity does not fit on the "Social Media" entity.
- To remove the "Person" entity, right-click on the model board and select Remove from Diagram.
Warning: Remove from Storage will remove the entity from storage, it means that it will be removed from the "Main Model" and all sub-models that the entity exists.
Remove from Diagram will remove the entity from the sub-model only.
Congratulations! You have successfully created the MovieActors sub-model.
Enjoy modelling using the Graph Modeller Tool! 😎🍕