假设如果搜索字符串不在FIELD()函数中作为参数提供的字符串列表中,那么MySQL将返回0作为输出。
示例
mysql> Select FIELD('Ram','New','Delhi');
+----------------------------+
| FIELD('Ram','New','Delhi') |
+----------------------------+
| 0 |
+----------------------------+
1 row in set (0.00 sec)