Things should consider while using Table Inheritance Hierarchy

 


Hello Everyone,
Hope you all doing well!

today I am going to share few important things that should be consider while implementing Table Inheritance hierarchy. 

1.       Design Guideline : Table inheritance data model should be avoided on transactional tables to minimize the performance impact. Always try to avoid creating extensively deep and wide table inheritance hierarchies when designing the physical data model.

2.       Record set operations:- AX doesn’t support using RecordInsertList and RecordSortedList classes for bulk inserts into table inheritance hierarchies. It will throw an error if you will try to use any one of them showing below :- 


“RecordInsertList or RecordSortedList operations are not allowed with tables participating in table inheritance

Trust me , I have experienced this error last week so thought it worth it to share. Instead,       Insert_recordset set operation can be used.

3.       Table Caching:- AX doesn’t support entire table caching on table inheritance hierarchy while record level caching is supported.

4.       Ad hoc query mode:- Always use Ad hoc query mode when you are queries data from table inheritance hierarchy. In other words, you should restrict the field list to only those fields required for business logic so always use select field list instead of select * to improve performance.

5.       Table buffer casting:- Direct upcasting is allowed between base and derived table record instances  and downcasting is allowed with help of is and as operators.

6.       FormData Source :- You should use “OnlyFetchActive” on table inheritance form and set its value to YES so form data source queries the back end database for only those fields that are bounded to form controls which improve performance by reducing SQL joins to the extra tables.



I hope this helps you

Comments