The Reverse Engineering tool is a feature newly added to the integrated development environment (IDE) of Microsoft Dynamics AX. This tool replaces Visual MorphXplorer which has been removed in version 4.0.
As the name suggest, this tool helps us retrieve detail information on the structures and relationships of Microsoft Dynamics AX objects. The retrieved information is transformed to a visually readable format in Microsoft Office Visio UML model. Technically, Dynamics AX will create a Microsoft Office Visio Drawing file (.vsd) using the Visio application component and construct a UML model with Visio UML add-on programmatically. Therefore you will need Microsoft Office Visio 2003 or greater with Visio UML model installed in order to use this tool.
Scoping Your Model
Naturally scoping required to create useful models. This allows us the flexibility to define what we want to include. In my opinion, a model of the complete Dynamics AX application would be too huge to be useful if not too time consuming to generate and maintain.
Dynamics AX Reverse Engineering tool scopes the model through development projects either private or shared. So you must first create a project and include the elements that you would like in your model in the project in order to generate a model.
Types of Model
This tool is capable of generating two types of model; data model and object model. Let's see what does these models capture and how do they differ.
Data model mainly captures tables. Tables within the project as well as tables referenced by them are included in the model. Tables within the project are grouped by the AX TableGroup property. They are organized under groups named Main, Group, Miscellaneous, Parameter, Transaction, WorksheetHEader and WorksheetLine. Referred tables will be placed under the group External Classes.
You will also find relevant information such as fields and its data type, indexes, and relationship of each table in the generated model. The data type of these fields is modeled in Dynamics AX Extended Data Type. Dynamics AX Extended Data Type used by the model is included under the group External Data Type. This is the same for Dynamics AX Base Enums. The referenced enumeration with their members is captured under group Base Enums.
Due to the use of Visio UML model, each of these tables will be represented by a class and fields are modeled as attributes. However, table method is not included here. Table method is an important feature of Dynamics AX development platform but methods are not quite relevant for data model.
Those that would like to have the methods included could use the object model instead. However, that model will not have data model information such as relationship and index.
Object model will capture classes, tables, and interfaces relevant to the project. This includes referenced objects as well. Tables and classes within the project are generated under the main group without further grouping. Referenced objects are placed under group External Classes just like Data Model.
The properties and methods of the classes are modeled as attributes and methods in the class diagrams. Table entities are modeled the same way too. Information synonymous to object model such as class extends another class, class implementation of an interface and call between classes are found in this model.
Data type that the properties and methods uses in the form of Dynamics AX Extended Data Type are included in the model under Extended Data Type group. The same happens to Base Enums.
The table generated in Object Model will have table methods modeled as method unlike those in Data Model. Since this is an object model, you will not find information such as field index and table relationship in this model.
Information | Data model | Object model |
Tables | Yes | Yes |
Related tables | Yes | Yes |
Table fields | Yes | Yes |
Table methods | No | Yes |
Table group property | Yes | No |
Field index | Yes | No |
Classes | No | Yes |
Referenced classes | No | Yes |
Extended Data Types | Yes | Yes |
Base Enums | Yes | Yes |
X++ Data Types | Yes | Yes |
How to Generate
This feature is only accessible through the context menu. The following are the steps to generate a UML model using this tool.
- Create a project and move the elements you would like in the model into this project.
- Right click on the project and select Add-Ins>Reverse Engineer.
- This will load a form named Visio Reverse Engineering. Enter the path and filename for the Visio drawing file.
- Select the model you want to generate then press OK. You may generate either data model or object model.
Conclusion
This is good news for those that are already using Microsoft Office Visio for their modeling tasks and is familiar with Visio UML model. I have tried my hands on Visio UML model years ago but have never developed a liking for it.
Those that have already got used to generating data model with Visio Data Model Diagram might find the data model reverse engineering redundant. I agree that Visio Data Model produces excellent model but it reverse engineer at the database level. The challenge with AX is that a lot of information is not implemented at the database. AX relies heavily on extended data type and enumeration implemented at the application level. Another challenge is AX implementation of temporary table which does not appear in the database.
These challenges are addressed with the use of AX Reverse Engineering tool. Field data type will be represented in extended data types. Information regarding extended data types and base enums are included in the model too. Temporary tables could be included in the model. This is something that even the MorphXplorer does not support.
Is this better than MorphXplorer, the tool it replaced? I see much more information compared to MorphXplorer. The outcome is more professional too.
5 responses :
re: Visio UML model
We have Visio 2007 but we get a COM-type error every time we try and start the Reverse Engineering Tool. We don't think we have the UML model installed and this may be the problem. I cannot find where to download it. Hope you can help.... Mike
Hi
I have Visio 2007 Installed and get no COM error. The process seems to run OK, bet when it is finished, the opened visio file is empty (no objects drawed). Do you have any clues? Regards, Sebastian
Hi Mike,
Sorry for late reply. Have been busy with something other than Dynamics AX for quite some time.
Regarding your question, UML model is part of Microsoft Office Visio 2007 installation. You should be able to select it when you install Visio.
Hi Sebastian,
I have not the installation to test at the moment. Base on my experience with Visio Reverse Engineering, the objects are not added to the page automatically. The model may just be too huge to cramp into one page. You should be able to find them in the object tree view at the sidebar.
I'm a noob - everyone at my company is a noob at AX09 - and I'm tasked with understanding all tables and relationships relevant to employees, as that's the first data set we're planning to import from our current systems. This includes employees, positions, hierarchies, etc. I want to understand how we're going to have to translate the data as we bring it into AX09.
I created a project, then brought in a bunch of tables that appeared relevant to me - DirPPartyTable, EmplTable, a number of HRPParty* tables -- and then did the Reverse Engineer.
The result was an empty Visio document. There were items on the left pane that were in my project, but nothing drawn in the main section.
I'm a noob, so perhaps I'm missing something obvious and will do further research. In the meantime, if anyone has any nuggets of wisdom to move me down the road I'd be most grateful.
Add your opinion