1

I'm attempting to use nest and elasticsearch to index records with a field that is not analyzed so regexp can be used against the field.

Using attributes:

[String(Index = FieldIndexOption.NotAnalyzed)]
public string Normalisedpath { get; set; }

Then calling automap:

client.Map<JobRequestView>(p => p.AutoMap());

Unfortunately this is not reflected in the mapping in elasticsearch.

"normalisedpath": {
    "type": "string"
},

I've tried delete the index so ES recreates it, is there something I'm missing here?

0

1 Answer 1

1

Turns out you have to make sure the index exists before attempting to map to it. :)

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.