|
Re: Number Conversion [message #667057 is a reply to message #667056] |
Wed, 06 December 2017 03:26 |
|
Michel Cadot
Messages: 68648 Registered: March 2007 Location: Nanterre, France, http://...
|
Senior Member Account Moderator |
|
|
You have to first validate your regexp expression:
SQL> select regexp_replace('Low count (3.6) with mostly mature lymphocytes. Advised CP Again.', '[^0.0-9]', '') from dual;
REGEX
-----
3.6..
So the error is expected.
Assuming the format is always what you posted (a single number with an integer part followed by a dot and a decimal fraction):
SQL> select regexp_substr('Low count (3.6) with mostly mature lymphocytes. Advised CP Again.','\d+\.\d+') from dual;
REG
---
3.6
[Updated on: Wed, 06 December 2017 04:58] Report message to a moderator
|
|
|
|