-
-
Save TheShubhamVsnv/254f0b529e033a52bc48eecc39765e86 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Record-level access in Salesforce defines the level of access a user has to individual records | |
within an object. This can be controlled through mechanisms like sharing rules, manual sharing, | |
criteria-based sharing, and ownership. Record-level access ensures that users can only view or | |
modify records for which they have the appropriate permissions. | |
*/ | |
public class RecordAccessExample { | |
List<Account> accList = [SELECT Id, Name FROM Account WHERE OwnerId = :UserInfo.getUserId()]; | |
// Accessing only records owned by the current user | |
// Code logic here | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment