Match either zero or one a character : Zero or One : Regular Expressions MySQL TUTORIALS


MySQL TUTORIALS » Regular Expressions » Zero or One »

 

Match either zero or one a character


mysql>
mysql> SELECT 'ABC' REGEXP '^Aa?C';
+----------------------+
'ABC' REGEXP '^Aa?C' |
+----------------------+
|                    |
+----------------------+
row in set (0.00 sec)

mysql>
mysql> SELECT 'ABC' REGEXP '^ABa?C';
+-----------------------+
'ABC' REGEXP '^ABa?C' |
+-----------------------+
|                     |
+-----------------------+
row in set (0.00 sec)

mysql>
mysql> SELECT 'ABC' REGEXP '^Ba?C';
+----------------------+
'ABC' REGEXP '^Ba?C' |
+----------------------+
|                    |
+----------------------+
row in set (0.00 sec)

mysql>



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

MySQL TUTORIALS

 Navioo Regular Expressions
» Zero or One