0

After adding a number field using the database configuration of Maximo and applying the changes, I quickly added the new field to the application using the Application designer.

To my surprise when I enter the number, it is displayed with comma separators (which I don't want).

i.e. 1000456 is entered and 1,000,456 is displayed.

How can I make Maximo display this as is, without the comma's to separate.

Update:

I have already searched for display option in the application designer and in the database configuration application, but I don't see anything about display options.

davejal
  • 6,009
  • 10
  • 39
  • 82

2 Answers2

2

I think this has to do with your localization settings. And the number is going to be stored without the commas. But if you're wanting the display to not have commas, I think the best way to get what you want is with an ALN-type attribute and an autoscript that does a regular expression match on the ALN to check for just digits being entered.

Preacher
  • 2,127
  • 1
  • 11
  • 25
  • Not exactly what I was looking for (to change it to ALN), but thinking it through I realize I won't be doing calculations with the number, so changing to ALN solves the problem. – davejal May 26 '16 at 13:23
0

I came across this same problem and this is the script I made in Python, it basically removes the characters from the string, I'm happy to help if anybody needs it:

numbers = ['0','1','2','3','4','5','6','7','8','9']
onlynumbers= ''
word = mbo.getString("DESCRIPTION")

for c in word:
    if c in numbers:
        onlynumbers = onlynumbers + c

mbo.setValue("DESCRIPTION",onlynumbers)
Morterox
  • 27
  • 1
  • what is `mbo`? Also, consider wrapping your code in a function and/or produce a minimal working solution / example. – norok2 Sep 22 '17 at 21:32
  • I forgot to mention that this was a script with a validation action point, mbo is the way to reference the object itself, in Java this would be "this" – Morterox Sep 10 '18 at 15:02