You receive the following error in the integration logs in the Management Reporter Configuration Console in Microsoft Management Reporter 2012 for Microsoft Dynamics AX 2012:

[AX 2012 Accounts to Account] has encountered an error. Processing will be aborted. Error text: Object reference not set to an instance of an object.

Additionally, the following error may also appear in the Event Viewer:

Caught Exception: [System.NullReferenceException] Object reference not set to an instance of an object.Stack trace:at Microsoft.Dynamics.Integration.Adapters.AX2012GL.DataAccessHelper.GetEnumLabelId(EnumMetadata enumList, Nullable`1 value) at Microsoft.Dynamics.Integration.Adapters.AX2012GL.DataAccessHelper.GetEnumLabelId(EnumMetadata enumList, Nullable`1 value) at Microsoft.Dynamics.Integration.Adapters.AX2012GL.AX2012GLAdapter.GetEnumValueLabelString(String enumName, Nullable`1 value) at Microsoft.Dynamics.Integration.Adapters.AX2012GL.AccountObjectProvider.PopulateAccountAttributes(SqlDataReader accountReader) at Microsoft.Dynamics.Integration.Adapters.AX2012GL.AccountObjectProvider.CreateAccount(SqlDataReader reader, Dimension mainAccountDimension, Int64 mainAccountRecId) at Microsoft.Dynamics.Integration.Adapters.AX2012GL.AccountObjectProvider.QueryAccountValues() at Microsoft.Dynamics.Integration.Adapters.AX2012GL.AccountObjectProvider.ReadObjectKeys(DateTime modifiedDate) at Microsoft.Dynamics.Integration.Service.Tasks.MapWork.ReadObjectKeyList(DbMap map, DateTime queryDate, Int32& count)at Microsoft.Dynamics.Integration.Service.Tasks.MapWork.ProcessRecordsImplementation(OperationType operationType)


This issue occurs because a post type that exists in the MainAccount table in the AX database but not exists in Application Object Tree (AOT).


To resolve this issue, follow these steps:

  1. Run the following SQL statement against the AX database to check the posting type of the accounts:

    select distinct (postingtype) from MainAccount
  2. Log on to AX and check the AOT. To browse to AOT, click Data Dictionary, click Base Enums, and then click LedgerPostingType. Check the properties of each item and note the EnumValues table.

  3. If differences are found between the MainAccount table and the EnumValues table in AOT, the accounts that contain invalid posting types have to have a valid posting type set.

    For example, use the following statement to update the MainAccount table in which an invalid posting type of 255 does not exist in AOT. This statement set the posting type to a valid kind of 0.

    update MainAccount set postingtype = 0 where postingtype = 255
  4. When you update the MainAccount table, you have to rebuild the Management Reporter Data Mart . To do this, follow these steps.

    1. Click Start, open the configuration console on the server.

    2. In the left navigation pane, click ERP Integrations.

    3. Select the integration that is being used and then disable the integration by clicking Disable Integration.

    4. Click Remove to remove the ERP integration.

    5. Click Management Reporter Services in the left navigation and stop both of the Management Reporter services.

    6. Backup and delete the DDB database in the Microsoft SQL Management Studio.

    7. Start the Management Reporter services.

    8. Click File and then click Configure to configure the ERP integration again.

    9. When the integration is configured, select the integration from the left side of the configuration console, and then click Enable Integration.

Need more help?

Expand your skills
Explore Training
Get new features first
Join Microsoft Insiders

Was this information helpful?

What affected your experience?

Thank you for your feedback!