[ QGIS ] – Regular Expression – Delete comma from thousands separator

In my table, the “population” field contains a “comma” as
thousands separator. Depending on the international settings, QGIS takes (obviously) these values as “correct” and shows wrong population values:

1,2980 instead 12980 (it is not a decimal value!)

To “correct” the “problem” create a new column and use the field calculator:

regexp_replace( "POP_FIELD", ',', ' ' )

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.


%d bloggers like this: