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
sai.sfsai.sf 

Soql

Hi All,

 

 soql in my class gives no records for some users whereas for sys admin we will get the record.Is that the user should have an access to a record ?Please help.

 

Thanks

Best Answer chosen by Admin (Salesforce Developers) 
sai.sfsai.sf

I got it.I have been using with sharing keyword in my class.I removed it and its working

All Answers

Suresh RaghuramSuresh Raghuram

check with user and profile based permisssion.

 

 

And the record level accessability.

sai.sfsai.sf

user has no access to the record.Do the user needs to have an access for the soql to return record?

sai.sfsai.sf

I got it.I have been using with sharing keyword in my class.I removed it and its working

This was selected as the best answer