You can cast the string latitude and longitude to float directly from the database using a custom SQL query. The query syntax will be like this:
SELECT <column1>, <column2>,... --Other Required Dimensions/Measures
CAST(<latitude> AS FLOAT) AS PackageLat,
CAST(<longitude> AS FLOAT) AS PackageLong
FROM <TABLE NAME>
1 of 1 people found this helpful
Thanks for this.
This was close, but it was still failing for some of the values were not interpreted as valid floats. After spending some time in front of the google machine, I was able to find a solution that worked for me. That was try_cast.
try_cast(ProfileAnswer.Value as float) AS LAT
That worked, and returned the non-valid values as NULL, which we can clean up later.
Thanks again for pointing in a direction.
Well, you are welcome, though you figured out the right answer.