I am trying to do a fuzzy search using rest from a c# script and have tested a few different ways without success.
This payload works:
string payload = "{ \"name\" : \"Peter\"}";
...which is a normal search after the name "Peter".
However, when trying to do a fuzzy search using the following payloads:
string payload = "{ \"q\": { \"name\": { \"$regex\": \".*Peter.*\" } } }";
Response:
Success response from DB: {"items":[],"hasMore":false,"count":0}
Next:
string payload = @" {""q"": {""name"": { ""$like"": ""%Peter%"" } } }";
Result:
Success response from DB: {"items":[],"hasMore":false,"count":0}
Next:
string payload = @" {""q"": {""$textContains"": {""name"": ""Peter"" } } }";
Result:
DB Error: BadRequestResponse: {"type":"http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1","status":400,"title":"The field name $textContains is not a recognized operator.","o:errorCode":"SODA-02002"}
Any help is highly appreciated.