Smart search with text field that contains numbers

Tom Troughton asked on November 11, 2015 19:19

I have a field on a page type. It's a text field, but is populated by a dropdown list which has integer values as the option keys. So I end up with an integer value in a database text field.

I want to search on this field, but I'm finding that even when I set this field to be searchable and tokenized, the field in my index is always empty.

The smart search index is a Pages index using Standard analyser. I've tried with other analysers too, but that field is always empty. I'm inspecting the index with Luke to confirm the indexed values. Does anyone have any suggestions?

Recent Answers


David te Kloese answered on November 11, 2015 22:55

Hi,

some ideas:

  • what index type did you use? think you'll need pages!
  • did you make sure to rebuild your search index after you've changed the page type's search settings?
    • any errors?
  • are the other search index settings correct
    • sites
    • cultures
    • indexed content (does it contain the correct page type? does it index the correct path?)
  • when you search for the page in the search preview does the page show in the results?

Greets,

David

0 votesVote for this answer Mark as a Correct answer

Tom Troughton answered on November 12, 2015 11:25

Hi. Yes, it's Pages. Yes I rebuilt. Yes, it's the correct page type etc. As I say, when I inspect the index content using an index inspector tool I can see the relevant pages in there and I can see the specific field I want is always empty.

0 votesVote for this answer Mark as a Correct answer

Tom Troughton answered on November 13, 2015 12:34

Apologies all. The issue here was not with indexes. The app was searching using an index for the wrong culture. The culture it was using didn't have the values I was expecting.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.