Extending Microsoft Dynamics 365 Finance and Supply Chain Management Cookbook - Second Edition
by Simon Buxton
Implementing table inheritance
Table inheritance can be implemented so that we have a base table with common attributes, as well as specializations that extend that table and add their own attributes and methods. This is similar to classes, but only in concept—although the base table can have many child tables, only one physical table is created in the SQL Server. The physical table in the SQL Server contains all of the fields from the base table and its child tables.
A good candidate for this is the vehicle table, where we could have a base vehicle table and a child table for each type, such as Bike, Car, and Truck. This is suitable as long as we are sure these can be considered physical data structures, and not a categorization. For example, ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access