I'm in a hurry, to avoid errors in CAML query, try to build the query using CAML Query Builder.

Hope this helps you.

CAML query with Five Condtion throws an Microsoft.Sharepoint.SPException
What do I need to grant permission for creating a service in Windows server 2008 R2?

I have added the user to the local "Administrators" group. 

This is the error message:

C:\temp&gt;sc create test  binpath=c:\temp\test.exe
[SC] OpenSCManager FAILED 5:
Access is denied.

