I have a Hierarchical Custom Setting that I need to SOQL use a SOQL query for using the current User's Profile.
Currently I'm using the getInstance() method with the User Profile ID to get the custom setting, then I update a field on it. The problem is that it frequently errors with the Unable_to_lock_row error.
I want to try using a SOQL and the FOR UPDATE to try to prevent this error from happening.