Reputation: 133
I'm running a Data Fusion pipeline with Wrangler transformations and I want to store a value as Numeric in BigQuery for some precise arithmetic calculations, but Wrangler doesn't let me transform a FLOAT value to NUMERIC.
I've tried with implicit conversion trying to write a FLOAT value into a NUMERIC column inside BQ but that didn't work.
Is there a workaround for this?
Thanks!
Upvotes: 0
Views: 307
Reputation: 842
You can use CAST() function for explicit conversion as it always converts any numeric type to another numeric type.
CAST(expression AS NUMERIC)
You can refer to this documentation for conversion rules and comparison chart.
Upvotes: 0