function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mms.testsmms.tests 

The SOQL to get User's photo URL and FeedItem together

How can I get User's photo URL and feeditem together in one SOQL statement?

 

Thanks!

Best Answer chosen by Admin (Salesforce Developers) 
digamber.prasaddigamber.prasad

You can't access them together using SOQL query. Available option is to use 2 different queries or user chatter REST Api to get feed-item and it will return url of actor too.

 

Let me know if you have any other question.

 

Happy to help you!

 

Regards,

Digamber Prasad

All Answers

digamber.prasaddigamber.prasad

You can't access them together using SOQL query. Available option is to use 2 different queries or user chatter REST Api to get feed-item and it will return url of actor too.

 

Let me know if you have any other question.

 

Happy to help you!

 

Regards,

Digamber Prasad

This was selected as the best answer
Jami GibbsJami Gibbs
You can access the user photo url in a single SOQL query now with TYPEOF:

https://blog.jamigibbs.com/get-user-profile-image-from-feed-item-soql-query/