|
|
Regular expression in mysql - Mysql
|
Views : 502
|
|
Tagged in : Mysql
|
|
|
Report This Scrap as Inappropriate We request you to choose the appropriate categroy and subcategory that suits your
objectionable concern about the scrap, So that our team can review and find out whether it violates our Guidelines or the
scrap is not suitable for all viewers.
|
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 |
|
|
|