Regular expression in mysql - Mysql Views : 481
Tagged in : Mysql
Send mail vote down 0 vote down 0
If you want to discard field value containing '-' in between the string, you can make use of following regular expression
NOT (exp REGEXP 'pattern')

Example
$sql=" select count(*) as count,substring_index(server,'/',2) as name from sitemap where
server like '%$server%' and NOT (server REGEXP '$server-') group by name order by count desc ";
By - kalai, On - 2009-07-20




    Login to add Comments .