如何以编程方式查询 ravendb 中 属性 为空的文档
How to programatically query for documents where property is null in ravendb
在ravendb studio我可以做:
property: [[NULL_VALUE]]
如何使用 IDocumentQuery
做同样的事情?
下面的尝试不起作用。
documentSession
.Advanced
.DocumentQuery<Doc, Index>()
.WhereIn("property", new[] {"[[NULL_VALUE]]", "some value"})
.ToList();
要查询 [[NULL_VALUE]]
或 [[EMPTY_VALUE]]
:
documentSession
.Advanced
.DocumentQuery<Doc, Index>()
.WhereIn("property", new string[] {null, ""})
.ToList();
在ravendb studio我可以做:
property: [[NULL_VALUE]]
如何使用 IDocumentQuery
做同样的事情?
下面的尝试不起作用。
documentSession
.Advanced
.DocumentQuery<Doc, Index>()
.WhereIn("property", new[] {"[[NULL_VALUE]]", "some value"})
.ToList();
要查询 [[NULL_VALUE]]
或 [[EMPTY_VALUE]]
:
documentSession
.Advanced
.DocumentQuery<Doc, Index>()
.WhereIn("property", new string[] {null, ""})
.ToList();