Views:

Applies to Product - Dynamics 365 Supply Chain Management


What’s happening?
The InventTransOrigin Table has a field named ReferenceId, which is defined to be 20 characters long, but it allows the insertion of 25 characters. This discrepancy leads to truncation when viewed through the front end or AOT table browser, while SQL queries reveal the full length of 25 characters.


Reason:
This arises because the field is defined to hold only 20 characters, but the data (container IDs) is 25 characters long. This behavior is expected due to the corresponding EDT extending from Num, which has a database string size of 100.


Resolution:

  1. Modify the Field Length in AOT:
  2. Open the InventTransOrigin table in the Application Object Tree (AOT).
  3. Locate the ReferenceId field and change its StringSize property from 20 to 25.
  4. Compile the changes.
  5. Update the Database Schema:
  6. After modifying the field length in AOT, synchronize the database to apply the changes.
  7. In the Dynamics AX development environment, right-click the InventTransOrigin table and select Synchronize.
  8. Verify the Changes:
  9. Once the synchronization is complete, verify that the ReferenceId field now accommodates 25 characters both in the front end (UI) and when queried in SQL.
  10. Test the Changes:
  11. Perform tests to ensure that the changes do not affect any existing data or functionality. Confirm that the full container IDs are now displayed correctly in the UI and AOT table browser.