+ Start a Discussion
JayNicJayNic 

Querying for KnowledgeArticleVersion orderd by CaseAssociationCount

Hi all,
I'm implementing KnowledgeArticles  - and I keep running in to issues with this architecture...

I cna't seem to get knowledge article versions sorted by the CaseAssosciationCount...

Here is the query I am  trying to run:
SELECT id FROM KnowledgeArticleVersion WHERE Language = 'en_US' AND PublishStatus = 'Online' AND ValidationStatus = 'Validated' ORDER BY KnowledgeArticle.CaseAssociationCount DESC


And I get my lovely error:
ERROR at Row:1:Column:138
Didn't understand relationship 'KnowledgeArticle' in field path. If you are attempting to use a custom relationship, be sure to append the '__r' after the custom relationship name. Please reference your WSDL or the describe call for the appropriate names.

What the hell SF? You're tellin me I can't query parent values? how am I supposed to enforce my where clause ?!
JayNicJayNic
*cough
AllenMannAllenMann
Did you ever get this to work? I am in the exact same situation where I have some customer SOSL that needs to return articles for a specific data category and sort by case association count.