description |
---|
Converts a string into a number (double) in the specified format. |
- expression: String to convert to a number.
- format: Format for number conversion.
Examples
{% code title="TO_NUMBER example" %}
SELECT TO_NUMBER('12374.0023', '#####.###')
-- 12374.002
{% endcode %}
{% code title="TO_NUMBER example" %}
SELECT TO_NUMBER('12374', '#####')
-- 12374.0
{% endcode %}