How set AND condition to ALL columns - php

前端 未结 2 1826
粉色の甜心
粉色の甜心 2021-01-22 12:18

In MY TABLE if I type

floor fly

table returns No matching records because Global Search php function search records insid

2条回答
  •  心在旅途
    2021-01-22 12:54

    This is a bit long for a comment.

    For this type of search, you might consider a full text index. The documentation is here. These implement the MATCH . . . AGAINST functionality.

    With such functionality, you can order the results by relevance. This means that you do not have to decide in advance whether the connector is "and" or "or" between multiple words. You can also implement a boolean search, which would allow for more complex complex logic, if you so desire.

提交回复
热议问题