For e.g. We have the column value ' 1.11+build.201701152243 '
Here we have combination of alphabets and numeric and special characters like + and .
Suppose we need to convert it to integer for comparison purpose.
We can convert like below.
CAST(REGEXP_REPLACE(<COLUMN_NAME>,'[^0-9]','') AS INTEGER )
This will first replace everything except digits with empty. After that it will convert that as Integer.
Then we can use that as int for aggregate function.
Here we have combination of alphabets and numeric and special characters like + and .
Suppose we need to convert it to integer for comparison purpose.
We can convert like below.
CAST(REGEXP_REPLACE(<COLUMN_NAME>,'[^0-9]','') AS INTEGER )
This will first replace everything except digits with empty. After that it will convert that as Integer.
Then we can use that as int for aggregate function.