![]() If you are modeling for a development initiative, such as data warehousing, you will continue from the business model to logical and physical modeling (note: logical modeling is an upcoming feature in Ellie, see our Q2 roadmap update). However, if the number of subtypes grows very large (dozen+), the model will usually become visually more complicated, reducing its readability to the average user. They could have different relationships with “outside” entities, or they could have different attributes – or it might just make sense from a communication perspective to ensure that the different subtypes are clearly displayed on the modeling canvas and defined in the Glossary. ![]() Subtypes are best used in situations where you know there are a certain number of “kinds” of an entity that behave differently. When to use subtypes and what to do with them later? Supertypes are displayed in a similar fashion, and naturally, you can navigate from an entity to another by just clicking on them. By hovering your mouse over these, you can see in which models the subtypes are being used. You can see in the above picture that in addition to the relationships this Supply item entity has to other entities, it also displays two subtype entities: Material and Service. This is an extremely powerful source of information in general: here you can see all the relationships your entity has in any model across the entire Ellie environment! Regarding subtypes and supertypes, this view has (now, after Ellie’s v3.7 update) even more interesting stuff. In the entity’s Glossary view, you can see the Relationships tab. You can even create subtypes within subtypes – in fact, there is no hard limit in Ellie for the number of nested subtypes! What are the relationships between Subtype-supertype?Īll Ellie’s entities have their own Glossary entry, which you can access either via the Glossary menu itself or by double-clicking on an entity on the canvas. If something is common for all subtypes, you can handle it on the supertype (parent) level. This is a very powerful pattern that, while giving you a better understanding of the big picture, also makes your models visually simpler, as you don’t have to repeat relationships from every outside entity to every subtype entity. (If you happen to wonder about the meaning of the various colors of the entities in this model, please refer to Modeler’s Corner #2!) This shows how we can define that User and Booking confirmation are things that link to all types of bookings, but Hotel for example is only linked to the relevant subtype. Having done that, our travel agency example might look like this:Īs you can see from the diagram above, the sub-entities can be neatly connected to “outside” entities at the same time as the parent entity is connected to others. Just click on an entity and drag it inside another, and they are glued together click and drag outside to un-glue. In Ellie, we use the box-within-a-box notation for subtypes. How to Add a subtype entity in an Ellie model? ![]() This means that subtypes are always mandatory and mutually exclusive. Any single instance of the entity always represents a single subtype in our travel agency, an individual booking is always for either a flight or a hotel – not both at the same time, and you clearly can book a ‘nothing’. This is an example of a situation where we should reach into our toolbox for a subtype structure.Īn entity can have two or more subtypes. Still, both are very similar, essentially in that the user logs into our fancy system, selects their desired flight or hotel, and books them. Clearly, there are two types of bookings: Flight booking and Hotel booking. With a single booking, you book a flight or a stay in a hotel. We have a system in which our users create Bookings. Let’s imagine we run a travel agency (not a great choice in 2021, but perhaps we are optimistic about the future!). These tools are repeatable patterns, and this time we’re going to cover a simple but yet very powerful one: entity subtypes. Now it’s time to think about using these blocks in the most efficient way.Ī good modeler has a toolbox from which they can draw various instruments when encountered with a suitable situation. ![]() The first three entries in our Modeler’s Corner series focused on getting your building blocks straight: identifying entities and utilizing Ellie’s entity categories to understand those entities better, and approaching the entities from the viewpoint of simple language: verbs and nouns.
0 Comments
Leave a Reply. |