Search code examples
axaptadynamics-ax-2012x++dynamics-ax-2012-r2

How to keep Prefix 0s for a real field in ax 2012


I have a real field in AX Table. When I save a number "099" its storing as "99". What properties I should change/ What I have to do to make sure that it saves it as "099" in the table instead of "99"? FYI: I want only real field in table not others like string.


Solution

  • It's not generally possible in AX. It's not really possible in SQL either.

    What you're talking about should most likely be a string with some custom logic.

    If you want the field to always be a certain length and have the preceding zeros added, you could use a computed column, but there are limitations. See: