I want to be able to query the database for email addresses matching a regex. An example of what I am trying to avoid is this:
In my database, I have a user with emailAddress of amy.user@gmail.com
I also have 700 users with the domain name @amyconsulting.com
The current search I have now will return 701 results instead of 1 when I try to search for Amy like so: ^.*amy.*$
How can I make this search only the characters before the @ symbol in the email address? Thanks in advance...