Last active
December 28, 2015 07:49
-
-
Save giraam/7467116 to your computer and use it in GitHub Desktop.
Retrieve only valid email addresses from a query in Oracle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT NVL(LOWER(T.EMAIL),'-')EMAIL | |
FROM TABLE_NAME T | |
WHERE REGEXP_LIKE(NVL(LOWER(T.EMAIL),'-'), '^[a-zA-Z0-9!#$%''\*\+-/=\?^_`\{|\}~]+@[a-zA-Z0-9._%-]+\.[a-zA-Z]{2,4}$'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment