I have one string "110:name:name.lastname@provider.com".
I want to create a regex such that the values before first colon should be only numerics i.e. 110, values before second colon should be only alphabets and third part should have a valid email id.
can anyone guide me
Three bits there. First and second are easy enough, third one is pretty much impossible with a regex.
Best you will be able to do is something like this:
You could be a bit more specific than .* for the parts either side of the @ for the email, but frankly the only way you’ll really know if an email address is valid is to talk to the mail server for the provided domain and ask.