mysql在哪里匹配 [英] mysql WHERE MATCH AGAINST

查看:82
本文介绍了mysql在哪里匹配的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在使用mysql和MATCH AGANIST时遇到问题.

I am having a problem with a mysql and MATCH AGANIST.

我在数据库中得到了这一行:

I got this row in my database :

1:{Czy jesteśmy tutaj sami};2:{Margit Sanoemo}

我想通过以下查询找到它:

I want to find this by following query :

SELECT * FROM data WHERE MATCH (params) AGAINST('*argi*' IN BOOLEAN MODE)

但是我有一个空行.

但是此查询:

SELECT * FROM dataWHERE MATCH (params) AGAINST('margi*' IN BOOLEAN MODE)

我想要我想要的东西.

您能帮我在参数上加上双**吗? AGAINST('*argi*' IN BOOLEAN MODE)

Can you help me with double ** in params ? AGAINST('*argi*' IN BOOLEAN MODE)

推荐答案

+

前导加号表示该单词必须存在 在返回的每一行中.

A leading plus sign indicates that this word must be present in every row returned.

-

前导减号表示该词一定不能 存在于返回的任何行中.

A leading minus sign indicates that this word must not be present in any row returned.

< >

这两个运算符用于更改单词的贡献 分配给行的相关性值. <运算符减少 贡献和>运算符增加它.请参见下面的示例.

These two operators are used to change a word’s contribution to the relevance value that is assigned to a row. The < operator decreases the contribution and the > operator increases it. See the example below.

( )

.将圆括号放在子表达式的周围,以便给它们 搜索中的优先级更高.

. Parentheses are put round sub-expressions to give them higher precedence in the search.

~

前导波浪号充当取反运算符,导致 单词对行相关性的贡献为负.这对标记很有用 喧闹的话.包含此类单词的行的评分将低于其他单词, 但不会完全排除,因为减号会完全排除在外 运算符.

A leading tilde acts as a negation operator, causing the word’s contribution to the row relevance to be negative. It’s useful for marking noise words. A row that contains such a word will be rated lower than others, but will not be excluded altogether, as it would be with the minus operator.

*

* 星号是截断运算符.不像其他 运算符,它被附加到单词或片段上,而不是前缀.*

*An asterisk is the truncation operator. Unlike the other operators, it is appended to the word, or fragment, not prepended.*

词组开头和结尾的双引号,匹配 仅包含完整短语(按其键入)的行.

Double quotes at the beginning and end of a phrase, matches only rows that contain the complete phrase, as it was typed.

这篇关于mysql在哪里匹配的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆