문제

esp-devs, i have a collection in a fast repository on which i use the following query to get all the entities in that collection.

:/xsearch?offset=0&hits=100&query=Anthony&view=collection01

However, this query is giving all the fields for every hit-record.

<HIT NO="1" RANK="101" SITEID="0" MOREHITS="0" FCOCOUNT="0">
  <FIELD NAME="name">anthony</FIELD>
  <FIELD NAME="employeeId">12345</FIELD>
  <FIELD NAME="department">aeronautical</FIELD>
</HIT>

I, however, am interested in only one field for every hit-record.

<HIT NO="1" RANK="101" SITEID="0" MOREHITS="0" FCOCOUNT="0">
  <FIELD NAME="employeeId">12345</FIELD>
</HIT>

is there any way to specify the only field i desire so that the response would contain only that for the hit-results.

Thanks, JUKE.

도움이 되었습니까?

해결책

The best way to do this is to create a View. The View can specify which fields and navigatores are returned in the results. For more information, please check my article.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top