Pergunta

I "accidentally" had some documents stored in RavenDB with all the properties camel-cased because of a setting made with the json serializer ( json.SerializerSettings.ContractResolver = new CamelCasePropertyNamesContractResolver(); ).

Now I'm storing new documents using Pascal-casing. Can I search for documents ignoring case of the property name?

Eg.

Old document format:
{
  name : "foo",
  someStuff : "buzz"
}

New document format:
{
  Name : "bar",
  SomeStuff : "baz"
}

Thanks!

Foi útil?

Solução

You would need to use the LuceneQuery to manually set the property name for the query.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top