Common Deployment Errors and How to Fix Them
Salesforce deploy failures are terse — a one-line component error that rarely says why it happened or what to do. This section decodes the common ones: what the message means, why Salesforce rejected the component, and how to fix it. In mtdt.io, these same failures carry a hint in Deploy History that explains the cause and the fix inline.
Errors covered
- "You cannot deploy to a required field" — a profile or permission set is trying to set field-level security on a universally required field. Drop that field's FLS entry.
- "Duplicate value found" / uniqueness clash — a record-type label collides with one on the target, a field is being made unique while duplicate data exists, or a profile/layout has a repeated entry.
- "No such column" after deploying a field — the field deployed but its field-level security didn't, so it's invisible to SOQL and the API until you grant Read.
- "Test only deployment cannot update a field from a Master-Detail to Lookup" — Salesforce blocks a Master-Detail ↔ Lookup conversion in a Validate (test-only) run; a real deployment is supported.
More errors are documented as we verify them end to end. If you hit a deploy error that isn't here, contact support — and check whether pre-deployment checks would have caught it before the run.