SharePoint Search for Boolean property values Issues

Very interesting , issue that I came across a few times and wasted some more time each time ( I guess I am getting old)

The Problem :

SharePoint search ( advanced webpart ) does not recognize the syntax for the boolean values

While the search refinement panel does work fine and ale to filter the result set on the boolean value just fine.

but it looks like that problem here is somthing like this.

On you Search

<PropertyDef Name=”CarIsBlue” DataType=”boolean” DisplayName=”Blue Cars only”/>

If you Select

[“Blue Cars Only”      is true ]

you don’t get any .

but the reverse of that works just fine

[“Blue Cars Only”      is false ]

You can detect that by checking the search syntax on the http request (url ) at the result page.


No Results

and If you select the false option


All Results

It is not a problem if documented (I guess) , so here is the Microsoft official documentation

A Discussion here

Temporary solution that works fine

this so called literal can be cast


You can define the search property query as a string while it is acutally a boolean.

so ,

In your property definition you can change that to

<PropertyDef Name=”CarIsBlue” DataType=”text” DisplayName=”Blue Cars only”/>

and Ask the users to type is the value (True , true , TRUE , Yes or yes)

that should work fine.

I hope the 2010 (or 201x version)  search engine folks can find a solution



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s