INVALID_FIELD No such column 'XXX' on entity 'YYY' - Salesforce
0.5 min read
|Problem
You are getting an error message like this when testing your Salesforce cart or running Order Download:
Make sure you have given read access to the column & entity listed in the error message below.
INVALID_FIELD: SELECT Id, AccountId, CreatedDate, PoNumber, OrderNumber, TotalAmount ^ ERROR at Row:1:Column:36 No such column 'PoNumber' on entity 'Order'. If you are attempting to use a custom field, be sure to append the '__c' after the custom field name. Please reference your WSDL or the describe call for the appropriate names.
Solution
This is due to a permissions issue in Salesforce.
- Look at the entity and column name displayed in the error message.
- In the sample above the entity is "Order" and the column is "PoNumber"
- Navigate to the specific field mentioned in the Salesforce Setup menu.
- Click the Set Field-Level Security button.
- Make sure it has read access or above.