solr中的内部加入引发无法解析错误

Inner join in solr raises cannot parse error

我有以下sql请求

SELECT "people".* FROM "people" INNER JOIN "match_scores" ON "match_scores"."person_id" = "people"."id" WHERE (match_scores.job_id = 859 and match_scores.score >= 25)

我想使用 solr 进行搜索,这是我的要求

http://<code>hostname:8983/solr/select?q=*:*&fq=
({!join from=person_id_i to=id_i}job_id_i:859 AND {!join from=person_id_i to=id_i}score_e:{25\.0 TO *})

它引发了以下错误:

"msg": "org.apache.solr.search.SyntaxError: Cannot parse 'score_e:': Encountered \"<EOF>\" at line 1, column 8.\nWas expecting one of:\n    <BAREOPER> ...\n    \"(\" ...\n    \"*\" ...\n    <QUOTED> ...\n    <TERM> ...\n    <PREFIXTERM> ...\n    <WILDTERM> ...\n    <REGEXPTERM> ...\n    \"[\" ...\n    \"{\" ...\n    <LPARAMS> ...\n    <NUMBER> ...\n    ",

没有理由尝试对同一个集合进行多次连接(而且我不确定单个 fq 中的多个连接是否会起作用)——你正在做的可以在两种情况下进行过滤:

{!join from=person_id_i to=id_i}job_id_i:859 AND score_e:{25.0 TO *]