I have a field called "sales" and the source data is piping in a value with a comma (ex: 1,000) instead of 1000 (without commas).
How can I convert this value to a numeric (without commas)?
Thanks in advance!
I have a field called "sales" and the source data is piping in a value with a comma (ex: 1,000) instead of 1000 (without commas).
How can I convert this value to a numeric (without commas)?
Thanks in advance!
This should work:
select replace(sales, ',', '')::numeric from tablename;
replace(sales, ',', '') to remove commas (',') and ::numeric to convert value to numeric.