• Nicholas Playoust
  • NEWBIE
  • 0 Points
  • Member since 2017

  • Chatter
    Feed
  • 0
    Best Answers
  • 1
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 0
    Replies
Hi,

I'm attempting to create a SOQL query (to merge data via Conga).  Specificically, I would like to retrieve records from the object "ContentVersions" as they relate to Files (ContentDocument) attached to a custom object called (Transmittal).  I am retireving them from Transmittal. I have written the following:
 
SELECT v.Title, v.FileType
FROM ContentVersion v
WHERE ContentDocumentId in
(Select j.ContentDocumentId From ContentDocumentLink j
Where j.LinkedEntityId = '{pv0}')

My query returns the following error, "Entity 'ContentDocumentLink' is not supported for semi join inner selects".

The sturcture, as I understand it is:
Transmittal
ContentDocumentLink (creates a m to m relationship between the Linked Entity (here Transmittal) and ContentDocument.
ContentDocument
Content Versions

I have reviewed the Content Object schema.

Is the query incorrect, or is it not supported?  If not what is a work-around? (Sorry I'm an amateur).

Thank for your help.
Hi,

I'm attempting to create a SOQL query (to merge data via Conga).  Specificically, I would like to retrieve records from the object "ContentVersions" as they relate to Files (ContentDocument) attached to a custom object called (Transmittal).  I am retireving them from Transmittal. I have written the following:
 
SELECT v.Title, v.FileType
FROM ContentVersion v
WHERE ContentDocumentId in
(Select j.ContentDocumentId From ContentDocumentLink j
Where j.LinkedEntityId = '{pv0}')

My query returns the following error, "Entity 'ContentDocumentLink' is not supported for semi join inner selects".

The sturcture, as I understand it is:
Transmittal
ContentDocumentLink (creates a m to m relationship between the Linked Entity (here Transmittal) and ContentDocument.
ContentDocument
Content Versions

I have reviewed the Content Object schema.

Is the query incorrect, or is it not supported?  If not what is a work-around? (Sorry I'm an amateur).

Thank for your help.