solr导入了多个entity,如何指定一个entity查询全部呢?

[复制链接]
查看11 | 回复1 | 2021-1-27 06:43:52 | 显示全部楼层 |阅读模式
经过资讯,查到了这个
IfyouhavedefinedanEntityforeachtableaswellasaCombinedone,youcanaddanidentifiertoeachoftheentityandusethatidentifiertofiltertheresults.
e.g.
AddafieldtypetoeachentitywithfixedvaluesasPERSON,LOCATIONCITY....
Andforqueriesusefq=type:PERSONtofiltertheresultsforthespecificentity.
但是如何给entity添加字段,并添加固定值没搞明白,请问该怎样添加字段跟固定值呢?
分 -->
回复

使用道具 举报

千问 | 2021-1-27 06:43:52 | 显示全部楼层
每一个entity加一个字段用来做标志比如user类每一个数据加一个字段falg:A,person加字段flag:B以此来区分
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行