| List: | General Discussion | « Previous MessageNext Message » | |
| From: | Yesmin Patwary | Date: | May 20 2006 2:47pm |
| Subject: | Find invalid email formats using MySQL query. | ||
| View as plain text | |||
Dear All,
My contact table has email field which contains many invalid email addresses. I find
them using following php function. Is there a way to do that check in MySQL query?
function emailValidate ($str)
{
$reg = "^([a-zA-Z0-9._-]+)@([a-zA-Z0-9-])+(\.[a-zA-Z0-9-]+)+$";
if (eregi($reg, $str)) {
return true;//-- good email
}else{
return false;//--bad email
}
}//--close function
Thanks in advance for any comments or help.
---------------------------------
Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at
1¢/min.
| Thread | ||
|---|---|---|
| • Find invalid email formats using MySQL query. | Yesmin Patwary | 20 May |
| • Re: Find invalid email formats using MySQL query. | Keith Roberts | 20 May |
| • Re: Find invalid email formats using MySQL query. | Peter Brawley | 20 May |
| • RE: Find invalid email formats using MySQL query. | fbsd | 20 May |
| • RE: Find invalid email formats using MySQL query. | Keith Roberts | 20 May |
| • RE: Find invalid email formats using MySQL query. | Chris Sansom | 21 May |
