SELECT LENGTH(TRIM(TRANSLATE(string1, ' +-.0123456789', ' '))) FROM DUAL;
OUTPUT
----------
LENGTH(TRIM(TRANSLATE('123b', ' +-.0123456789',' '))); | would return 1 |
LENGTH(TRIM(TRANSLATE('a123b', ' +-.0123456789',' '))); | would return 2 |
LENGTH(TRIM(TRANSLATE('1256.54', ' +-.0123456789',' '))); | would return null |
LENGTH(TRIM(TRANSLATE ('-56', ' +-.0123456789',' '))); | would return null |
No comments:
Post a Comment