返回str 在str1, str2, str3, ...列表其中的索引(位置從1開(kāi)始)。返回0,如果str沒(méi)有找到。
SQL> SELECT FIELD('ej', 'Hej', 'ej', 'Heja', 'hej', 'foo'); +---------------------------------------------------------+ | FIELD('ej', 'Hej', 'ej', 'Heja', 'hej', 'foo') | +---------------------------------------------------------+ | 2 | +---------------------------------------------------------+ 1 row in set (0.00 sec)