to char - Oracle SQL: How do I convert the substrings in a string using to_char -
the to_char works fine when applied single match below.
select to_char('54523234', '99,999,999,999')
i use regex find match of currencies in string. when apply to_char first group, doesn't work
select regexp_replace ('24444.88, 54523234.78, , 1044.52 numbers in example.', '(([0-9]+){1,10})+\.([0-9]{2})', to_char('\1'.'99,999,999,999')) dual;
i want output string displayed like: 24,444.88
, 54,523,234.78
, 1,044.52
numbers in example.
here go brother, fun one:
select regexp_replace(regexp_replace ('234234234.88, 24444.88, 54523234.78, , 1044.52 numbers in example.', '(([0-9]{3})\.)', ',\1'),'(([0-9]{3}),)',',\1') dual
Comments
Post a Comment