A Programmer's Dream

Outlook's Query Builder

Posted by Stephen Wrighton on 04 Jul 2010

In Outlook 2007, Microsoft did something that well, I find odd. They coupled the Advanced Search functionality of the Outlook product into the Windows Desktop Search (or the "Windows Search 4.0" if you prefer).  The reason I find it odd, is that from what I've read no one likes Windows Desktop Search. Of course, it's hard-baked into Windows Vista and later, so some folks never had a chance.

Well, that's all fine and good, until you get to Windows Server 2008 service pack 2.

Which of course, is the operating system I'm dealing with.  You see, I have two Server 2k8 sp2 boxes working as terminal servers (with NTLB making them into a TS Farm), and have installed Outlook 2007 on them.  Well, the migration from the old terminal servers was going well and we got the users on the new boxes, complete with their 12-14GB inboxes.

And with inboxes that big, you can't not have advanced search capabilities.

Which is exactly what happened.

The users opened up Outlook, popped down the Query Builder tab and was presented with this:


Now, whenever you search about this issue, you're presented with a couple of interesting facts:

  1. If Query Builder is disabled, so is the Instant Search bar (the one right there at the top)
  2. Both Query Builder and Instant Search are dependent upon Windows Desktop Search/Windows Search 4.0

So, I'm quickly slamming my head against the table top where I'm working because I've got the following two facts going on:

  1. Windows Desktop Search/Windows Search 4.0 is not installed on my server
  2. Instant Search is working, just none of the "advanced" features

Which is an obvious impossibility according to everything that is being reported on the internet about how search in Outlook works.

So after fruitlessly searching the internet for more information, I give up in despair and call into Microsoft support. After the grilling phone call regarding how this is impacting my customer's business, I was promised  a callback within the usual 2 hours, and went back to searching to fill the time.

Well, an hour and a half later, I get my call back, and explain the problem.

Then I get on the Easy Assist tool and showed the Tech exactly the problem.

Then I got put on hold.

And thus, I waited in a soundless Limbo.

And waited.

And waited.

And waited.

Finally, the tech came back on the line, and I find out what I've been waiting for. Apparently, he had gotten his supervisor and a couple of other techs and built a Server 2008 environment and dropped Outlook 2007 on it to witness this for himself.

Of course it worked this way, and he came back with the statement: "You need to install Windows Desktop Search in order for the advanced search features to work in Outlook 2007."

Which in his defense IS the party line, and level one tech support ALWAYS follows the party line.

Of course, if solving this was something simple like installing WDS I wouldn't have had to call technical support.

So, since I had been EXPECTING this response, I let out my superior knowledge of my situation, and informed him that WDS refuses to install on Enterprise Server 2008 Service Pack 2. In fact when I tried to install, the installer told me that it was not for my version of Windows.

Additionally, I didn't want WDS as it's something of a resource hog, and when 60 folks are running on a terminal server at one time, well, resource hogs aren't necessarily good things.  But, I could handle a resource hog, if it got me the needed functionality, but again, it would not install so that was something of a moot point.

Well, informing the tech of this got me put back on hold, and the soundless Limbo.

Where I waited some more.

And some more.

By this time, I had been on the phone for the better part of an hour, most of it on hold.

Finally, he returned, and told me that he was going to have to get in touch with the special server support group for more information (my assumption is because he's realized that he can't get WDS installed on his 2008 test environment).

And here's some speculation as to what's happened so far in regards to development efforts and this situation:

Office 2007 was released and built to use the Windows Desktop Search search APIs. Then when Windows 2008 sp2 was released, it no longer supported the installation of WDS, and the Server OS team didn't talk to the Office team so no one knew to test that particular functionality.

My speculation up there is based upon the fact that nothing in the Office documentation tells you how to enable the Query Builder without the enabling of Instant Search. According to the documentation they are tied together intimately, and tied around Windows Desktop Search/Windows Search 4.0.

Digression aside, as the tech is telling me that we need to push this over to the server support group, I lay done my final trump card: during that two hour wait time, while I had been searching, I stumbled across an article on how to enable search services on Windows 2008 sp2, and doing so APPEARED to activate the Query Builder.

Basically, turning it on, made the screen look like this:


And the query builder appeared to work. Of course, what this is doing to my terminal server I have no clue, as I had drain-stopped this particular node of my TS Farm so I could tinker with it, thus I did not have the expected 50-60 users utilizing it at one time.

Worse, I have some reservations about this solution.  First, I'm running Outlook in ONLINE mode, and Search Services are only supposed to be impactive on the Outlook search if you're running in cached mode.  Second, Microsoft does not recommend Search Services for Enterprise grade servers (they're pushing SharePoint Services for search there). 

And that's the ultimate question I'm trying to get answered from Microsoft. What is this going to do customer's experience on their TS Farm, and if this is going to impact my customer's TS experience, how can I get them that stupid Query Builder.

Anyways, to activate the search services here, you perform the following steps:

  • Start Server Manager
  • Click Roles in the navigation tree on the left
  • Select Add Role in the Roles Summary section
  • Select the File Services role and click next
  • Select the Windows Search role service
  • Additionally, when I activated the system, I did not allow the Search Service to actually index anything—as I'm hoping that that will keep this from eating up resources.

    Now, it's just a waiting game to see what Microsoft comes back with here. 

    Tweet me @kidananubix if you like this post.