I have the following expression that is working to catch multiple emails or one single reserved word (eg. STACK, STACK_OVERFLOW).
^(([a-zA-Z\-0-9\.\_]+@gmail.com)[;]*)+$|^([A-Za-z]+\_?[A-Za-z]+)$
But when I try to use it in a condition like for example:
SELECT 1
FROM DUAL
WHERE REGEXP_LIKE ('stack_overfow@gmail.com', '^(([a-zA-Z\-0-9\.\_]+@gmail.com)[;]*)+$|^([A-Za-z]+\_?[A-Za-z]+)$');
It doesn't give me null, it gives me an error instead
ORA-12728: invalid range in regular expression
12728. 00000 - "invalid range in regular expression"
*Cause: An invalid range was found in the regular expression.
*Action: Ensure a valid range is being used.
What could be the cause?