SolrInputDocument中的addField
当我添加字段addField(“category”,“cat1”);它不会出现在搜索结果xml中,只有两个字段需要添加,即“id”和“名称”,任何人都可以告诉我如何添加另一个字段并出现在schema.xml的xml结果中。如果将字段设置为“存储”,它将显示在结果中SolrInputDocument中的addField,solr,solrj,Solr,Solrj,当我添加字段addField(“category”,“cat1”);它不会出现在搜索结果xml中,只有两个字段需要添加,即“id”和“名称”,任何人都可以告诉我如何添加另一个字段并出现在schema.xml的xml结果中。如果将字段设置为“存储”,它将显示在结果中 <field name="internal_id" type="string" indexed="true" stored="true"/> <field name="desc" type="text
<field name="internal_id" type="string" indexed="true" stored="true"/>
<field name="desc" type="text" indexed="true" stored="true"/>
定义要添加到schema.xml中的字段,并在使用“ADDFIELD”时使多值为true。您能发布代码吗?是否在schema.xml中添加了“category”字段?