Pattern Matching with LIKE : Like « Select Clause « SQL / MySQL






Pattern Matching with LIKE

       
mysql>
mysql>
mysql> SELECT 'MySQL' LIKE '%sql';
+---------------------+
| 'MySQL' LIKE '%sql' |
+---------------------+
|                   1 |
+---------------------+
1 row in set (0.00 sec)

mysql>

   
    
    
    
    
    
    
  








Related examples in the same category

1.Use LIKE
2.Use LIKE for matching substring
3.Pattern match with LIKE
4.Where clause: like and %
5.Where clause: regular expressions
6.Where clause: regular expression 2
7.Use LIKE in where clause
8.SELECT 'AA' LIKE 'A%', 'AA' LIKE 'A\%', 'A%' LIKE 'A\%';
9.Using LIKE with SQL Pattern Matches
10.To invert a pattern match, use NOT LIKE rather than LIKE: