Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
这是我的查询:
SELECT firstName, lastName FROM users WHERE users MATCH 'firstName:joh*'
我想获取lastName长度为1+(非空)的所有行
我应该如何修改我的查询?
FTS 无法做到这一点;只需使用普通表达式:
SELECT firstName, lastName FROM users WHERE users MATCH 'firstName:joh*' AND length(lastName) >= 1
(请注意,NULLand ''(空字符串)是不同的值,都被排除在外。)
NULL
''