Items not included SharePoint search results if a property missing
I use an MSSQLFT query to poll Sharepoint's search through Search.asxm
web service.
The query goes like this:
SELECT PreferredName, Department, AccountName, MobilePhone, WorkPhone
Title, JobTitle开发者_如何转开发, OfficeNumber
FROM SCOPE()
WHERE
"scope"="People" AND JobTitle="Something"
ORDER BY
Department, OfficeNumber
Some people do not have Depmartment
attribute set and hence are not included in search results.
Have you tried including the Department field in the where. You might have to hack it to say something like AND (dept = '' or dept not null). In other words, any value is acceptible. That would get the rows included in the results so the Order By clause could operate on them.
精彩评论