Can I add the comma "," to force the decimals to remove from the attribute and replace with the number?

For example, I have an Acres field column that says 506320.0750 and I want to replace the decimal with the comma, say 506,320? I want that number to be permanment.

Is that possible? I'm using ArcGIS Desktop 9.3.1

  • Is this more a question of the region settings on your computer? You can set the decimal symbol there (for example, in Windows 7, you can find this in the Region and Language control panel in the Additional Settings). This is what ArcMap uses to display numerical, date, and time formats. – kenbuja Oct 18 '11 at 20:38

If you force it you would need to convert from numeric to text.
What you want to do is change the display. Open the field properties dialog by right clicking on the field name in the attribute table..
Field properties
click the ellipses next to numeric...
then in the number format dialog select the number of decimals you desire.
then show thousands seperator check box.


  • Brad, that is what I did but it is NOT permanment. So if you set that up and then decided to bring the layer back in ArcMap again, it does not show the comma. YOu will have to do manual all over again. That is crazy ! – PROBERT Oct 18 '11 at 20:04
  • 3
    You might be able to use a layer file to save the number formatting with the layer for later use. Haven't tried it myself but it "should" work. – blah238 Oct 18 '11 at 20:15
  • 1
    I agree with blah and just tested it. save an lyr and whenever you add that data add the lyr instead. – Brad Nesom Oct 18 '11 at 21:34

Brad's suggestion to use the built-in number formatting functionality is wise -- it seems like a bad idea to permanently convert a decimal number to a formatted string in a table.

That said, if you really want to do this, read on:

If the Acres field type is Text, you can use the VBScript FormatNumber function which by default adds thousands separators. Set the first argument to the Acres field and set the second argument to 0 to truncate (or round, not sure which it does) the decimal portion. Be sure to make a backup as this is a destructive operation.

e.g. FormatNumber(cint([ACRES]), 0) (note the string to integer conversion)

If the Acres field type is Float or Double, you would have to add another field of type Text and calculate it in a similar way:

FormatNumber([ACRES], 0)

Note: It is likely these methods will fail on records with null values so do a select by attributes first to select non-null records, e.g."ACRES" IS NOT NULL

  • Thank you. So blah238, what is the reason for a bad idea to permanently in a table ? Why not ? To me it is easy for one to read quicker rather than doing the manually thing. I notice that ArcGIS assigned numbers into deciamls if you set up a field columns. Thanks – PROBERT Oct 18 '11 at 20:28
  • 1
    You said it yourself, what may be easier for you to read might make it more difficult for someone else. That's partly why using the built-in number formatting Brad suggested is a good idea, so different users can view the same data different ways. Also, databases use specific data types for size, performance, sorting and querying reasons, and using a text column to store a number is usually bad. You're also losing information by truncating the decimal portion, and inserting redundant data by inserting thousands separators that just make it harder to actually use the data rather than view it. – blah238 Oct 18 '11 at 20:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.