Thursday, May 5, 2011

SharePoint: Did you know that......CAML Query OrderBy not working???

So this one time I was creating a SharePoint view programmatically, whose items I wanted to be ordered as "Most recent item must be top". This meant ordering by the "Created" column in descending order.

So I used the following query:





And I wondered why this was not working. After a lot of research, I found that actually, its CASE SENSITIVE...aaarrrrgggghhh!!!

False is supposed to be FALSE, and the query should be:





And there you have it. I hope this will save someone some time.

No comments: