postgresql - 我怎样才能使除停用词之外的所有内容都被索引

标签 postgresql postgresql-9.2

我读到过在 Postgres 中使用字典时,如果一个词不被任何字典识别,它就不会被索引。我觉得这很麻烦。我希望除停用词之外的所有内容都被编入索引。

我可以吗?如果是,怎么办?

最佳答案

关于dictionaries的文档章节说:

The general rule for configuring a list of dictionaries is to place first the most narrow, most specific dictionary, then the more general dictionaries, finishing with a very general dictionary, like a Snowball stemmer or simple, which recognizes everything

因此,由于列表的最后一个字典,不会发生转储无法识别的单词。

这就是全文解析器开箱即用的工作方式,因此除非您自定义它,否则您不必担心它。

关于postgresql - 我怎样才能使除停用词之外的所有内容都被索引,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14301300/

相关文章:

json - PostgreSQL - 在不指定键的情况下聚合 JSON 对象中的值

postgresql - postgres - 估计时间戳列的索引大小

postgresql - 如何删除 Postgres 9.2 中的死行版本

postgresql - 我们如何让 “statement_timeout” 在函数内工作?

postgresql - 从 PostgreSQL 函数返回 SETOF 行

python - 在 python 中存储和查询序列

postgresql - 在Postgres中的时区之间转换

sql - rails : query the existence of a join table's child

sql - 用于检查数组中的枚举值的 PostgreSQL 函数

sql - 查询在 PostgreSQL 中除以零错误