Mega Code Archive

 
Categories / MySQL / Regular Expression
 

Limit the match on the i to either zero or one

mysql> mysql> SELECT 'iaiiiiin' REGEXP 'iai?n'; +---------------------------+ | 'iaiiiiin' REGEXP 'iai?n' | +---------------------------+ |                         0 | +---------------------------+ 1 row in set (0.00 sec)