2

We have an Endeca index configured across multiple fields of email content - subject and body. But we only want searches to be performed on the subject lines. Endeca is returning matches within the bodies too. How do you limit the search to the subject?

3 Answers3

3

You can search a specific field or fields by specifying it (them) with the Ntk parameter.

Or if you wish to search a specific group of fields frequently you can set up an interface (also specified with the Ntk parameter), that includes that group of fields.

Wiszh
  • 511
  • 5
  • 20
1

This is how you can do it using presentation API.

final ENEQuery query = new ENEQuery();
final DimValIdList dimValIdList = new DimValIdList("0");
query.setNavDescriptors(dimValIdList);
final ERecSearchList searches = new ERecSearchList();
final StringBuilder builder = new StringBuilder();
for(final String productId : productIds){
    builder.append(productId);
    builder.append(" ");
}
final ERecSearch eRecSearch = new ERecSearch("product.id", builder.toString().trim(), "mode matchany");
searches.add(eRecSearch);
query.setNavERecSearches(searches);

Please see this post for a complete example.

Sanju Thomas
  • 181
  • 2
  • 10
0

Use Search Interfaces in Developer Studio.

Refer - http://docs.oracle.com/cd/E28912_01/DeveloperStudio.612/pdf/DevStudioHelp.pdf#page=209

KrishPrabakar
  • 2,824
  • 2
  • 31
  • 44