• Global community
• Language:
• Deutsch
• English
• EspaÃ±ol
• FranÃ§ais
• PortuguÃªs
• æ—¥æœ¬èªžã‚³ãƒŸãƒ¥ãƒ‹ãƒ†ã‚£
Dedicated community for Japanese speakers
• í•œêµ­ ì»¤ë®¤ë‹ˆí‹°
Dedicated community for Korean speakers
Exit
• Delete space after number in tables

# Delete space after number in tables

New Here ,
Mar 08, 2023 Mar 08, 2023

Copied

I need to convert all my numbers from what I think is the french way to American/English.
Ex:
1 023 696 Correct 1,023,696
0,04 correct 0.04

I've found a Grep style converting all space to, that's brilliant, except that all my numbers have a space at the end so I end up with a comma at the end as well...

Does anyone know how I can delete space after a number in a table cell?

TOPICS
How to , Type

Views

461

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Community Expert , Mar 08, 2023 Mar 08, 2023

Find

\h(?=\d{3})

This finds any horizontal space - looks ahead for 3 digits

Technically

1 00 - won't work

1 000 replaced by 1,000

1 000 000 replace by 1,000,000

and so on

The other grep would be

(\d),(\d{2})

\$1.\$2

Community Expert , Mar 09, 2023 Mar 09, 2023

GREP looks for patterns - so if the pattern doesn't fit you need another pattern.

It might be possible - you'd have to give examples of live text to test fully.

Community Expert , Mar 09, 2023 Mar 09, 2023

Space-comma replacement:

``````Find what: \d\K\h(?=\d\d\d)
Change to: ,``````

4 Replies 4
Community Expert ,
Mar 08, 2023 Mar 08, 2023

Copied

Find

\h(?=\d{3})

This finds any horizontal space - looks ahead for 3 digits

Technically

1 00 - won't work

1 000 replaced by 1,000

1 000 000 replace by 1,000,000

and so on

The other grep would be

(\d),(\d{2})

\$1.\$2

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
New Here ,
Mar 08, 2023 Mar 08, 2023

Copied

Thanks! It almost works like magic! Some numbers like 156 have a space in front and end up ,156. Anyway to get around that?

The other grep works perfectly!

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Community Expert ,
Mar 09, 2023 Mar 09, 2023

Copied

GREP looks for patterns - so if the pattern doesn't fit you need another pattern.

It might be possible - you'd have to give examples of live text to test fully.

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Community Expert ,
Mar 09, 2023 Mar 09, 2023

Copied

LATEST

Space-comma replacement:

``````Find what: \d\K\h(?=\d\d\d)
Change to: ,``````