Your Business Central Extension Publishes in Sandbox and Fails in Production With a Field Conflict

How to find which app and which field clash, the three ways to fix it without losing data, and the release checks that stop the next conflict reaching production.

Diagnose before you rename anything. Compare the installed apps and their versions in the sandbox and in production on the Extension Management page or in the admin center, because the usual cause is an app or a newer app version that exists only in production. Read the error for the base table, the clashing field or object name and the other publisher, then check your affix and ID ranges against that app. Three fixes work: rename your field with your affix and move any data with an upgrade codeunit, agree a change with the other publisher, or isolate the dependency in your own table. Prevent a repeat by testing in a sandbox copied from production.

Why does an extension publish in sandbox and fail in production?

Because the two environments are not running the same set of apps. Table extensions from different apps all add fields to the same base table, so a field name or field ID that is free in the sandbox can already be taken in production by an ISV app, another per-tenant extension, or a newer version of an app that added fields since the sandbox was created. Business Central refuses the second definition when you publish or install, and the error names the table and the field.

The usual reasons the sandbox looked clean: it was created empty or from production months ago, an ISV app was updated in production but not in the sandbox, a per-tenant extension was installed in production by someone else, or the sandbox was on a different Business Central version with different symbols. None of these is a bug in your code; it is a gap in the release path, and the fix has two parts, the conflict now and the process afterwards.

What do you check first when the error names another app?

Start with facts you can read, before anyone renames a field. The goal is to know exactly what clashes with what, and which version of which app put it there.

  • The error text: base table, field or object name, ID, and the other app or publisher. Save the full message and the version of your app that failed.
  • Installed apps in both environments: name, publisher and version from Extension Management in Business Central, or the Apps list for each environment in the Business Central admin center. Put them side by side.
  • The other app: is it an AppSource app with a registered affix, or a per-tenant extension written for this customer? Who maintains it, and when was it last updated?
  • Your affix: does every field and object in your table extensions carry your prefix or suffix? A field called Status or Region without an affix is the classic clash.
  • Your ID range: does app.json idRanges overlap with another per-tenant extension in the customer range 50000 to 99999? Two per-tenant extensions from different authors often both start at 50100.
  • Your production history: has any version of your app ever been installed in production? That decides whether a rename is free or needs an upgrade.

Is the clash a field name, a field ID or an object ID?

Each kind has a different fix, so classify it before choosing.

ClashTypical causeDirection of the fix
Field name on a base tableTwo table extensions add a field with the same name, often a generic name with no affixRename your field with your affix; move data if it was ever installed
Field ID on a base tableTwo per-tenant extensions use the same field number range on the same tableMove your fields to free IDs inside your own range; move data if it was ever installed
Object name or ID in the tenantTwo per-tenant extensions both claim a table, page, codeunit or report ID or name in 50000 to 99999Agree separate ranges per author and renumber the app that has not been installed yet
Same concept, two appsYour app and the other app both add, for example, a delivery window field to the same tableConsider a dependency on the other app and use its field instead of your own

How do you rename a field with an affix without losing data?

If no version of your app with the clashing field has ever been installed anywhere that holds real data, rename it with your affix in the new version and publish. There is nothing to move.

If an earlier version is installed somewhere with data, for example in another customer's production or in a sandbox the customer uses for real work, treat it as a schema change. Add a new field with your affix and a free ID, write an upgrade codeunit that copies values from the old field to the new one in OnUpgradePerCompany, guarded by an upgrade tag so it runs once, and point every page, report, API and integration at the new field. Mark the old field ObsoleteState Pending with a reason, and remove it in a later version once nothing reads it. Microsoft describes upgrade codeunits and upgrade tags under upgrading extensions.

Test the upgrade from the exact version installed in production, not from the version on your laptop.

When should you coordinate with the other publisher instead?

When the other app is the one breaking the rules, or when both apps mean the same thing. An AppSource publisher registers an affix with Microsoft and is expected to use it; a field without that affix in their app is a defect you can report with the error, both app versions and the base table. A per-tenant extension written by another party for the same customer can usually agree a split of ID ranges and affixes in one conversation, and the customer, who owns both, can make that a rule.

If both apps add the same concept, say a delivery window on Sales Header, consider declaring a dependency on the other app and reading its field rather than adding your own. That removes the clash and a duplicated data entry, but it ties your release to theirs, so only do it when the other app is stable and the customer intends to keep it.

How do you isolate your extension from another app it collides with?

By keeping your data out of the shared space. Instead of adding several fields to a base table through a table extension, add one table of your own keyed on the base record, such as Document Type and No. for a sales header, and show it on the page through a page extension part or a FactBox. Your table and its field names are yours alone, so later updates to other apps cannot collide with them.

The trade off is a join wherever you need the data, in reports, APIs and filters. Use it for groups of fields that belong to your feature, not for one field that users filter on every day. For the runtime side, where several apps subscribe to the same posting events and break each other after an update, see ISV extension conflicts after an update.

What does the fix look like step by step?

A sequence that works whether the clash is a name or an ID, and whether your app is new to production or an upgrade.

StepWhat to do
1. Capture the exact errorCopy the full publish or install error from production: the base table, the field or object name, the ID and the app or publisher it clashes with. Keep the app versions you tried to deploy.
2. Compare the app listsList installed apps with publisher and version in production and in the sandbox, from Extension Management or the admin center, and mark every app or version that exists only in production.
3. Reproduce on a production copyCopy production to a new sandbox, download symbols from it, and compile and publish your app there. The same conflict should now appear in the sandbox, where you can work on it.
4. Identify name or IDDecide whether the clash is a field or object name, a field ID within the base table, or an object ID within the tenant, and check your affix and your app.json idRanges against the other app.
5. Choose the fixRename your field or object with your affix if it has never been installed in production. If it has data somewhere, add an affixed field, move the data in an upgrade codeunit and mark the old field obsolete. Agree a change with the other publisher, or move your fields into your own table.
6. Test the upgrade pathIn the production copy, install the current production version of your app, add sample data, then upgrade to the fixed version and check that data, pages, reports and integrations still read the right fields.
7. Deploy and preventDeploy in a maintenance window, then make the production copy sandbox and an affix rule part of every release so the next conflict is caught before production.

How do you stop the next field conflict reaching production?

Make the release path test against what production really runs.

  • Before each release, copy production to a sandbox in the admin center, or refresh an existing one, so apps, versions and data match production.
  • Compile against symbols downloaded from that sandbox, not from a local container with a different app set. A pipeline that does this is described in a build and release pipeline for one Business Central developer.
  • Turn on the code analysers and set your affix as mandatory in AppSourceCop configuration, so an unaffixed field fails the build.
  • Keep a register of ID ranges per author for every per-tenant extension in the tenant, owned by the customer.
  • Ask the customer to tell you when an ISV app is added or updated in production, or check the app list as part of every deployment.

What does Solzet do when an extension will not install in production?

Solzet reproduces the conflict on a copy of production, identifies the clashing field or object and the app behind it, renames or renumbers with your affix and writes the upgrade code that moves existing data, or agrees the change with the other publisher on your behalf. We then set up the production copy sandbox, symbol download and affix rules in your release path so the next version is tested against what production runs. Our own senior AL developers do the work, under your source control. The service line is Business Central AL development; broader implementation is on Dynamics 365 Business Central.

Where the customer data around the ERP lives in a CRM, organisations that would rather not carry Microsoft licensing for it can choose a custom CRM. We recommend the right solution: Dynamics 365 (Customer Engagement, Business Central or Finance and Operations), Power Platform, or a custom-built CRM. One team for CRM, ERP and the integration between them.

What do people ask us?

Why does my Business Central extension install in sandbox but fail in production?

Almost always because production runs an app or a newer app version that the sandbox does not, and that app already defines a field or object with the same name or ID. Compare the installed apps and versions in both environments and read the clashing app from the error.

Can two extensions add a field with the same name to the same table?

No. Fields added by table extensions share the base table, so names and IDs must be unique across every app that extends it. That is why AppSource publishers use a registered affix and per-tenant extensions need agreed ID ranges.

How do I rename a field that already holds data in Business Central?

Add a new field with your affix, copy the data in an upgrade codeunit guarded by an upgrade tag, move every page, report and integration to the new field, mark the old field ObsoleteState Pending and remove it in a later version.

What is an affix in Business Central development?

A prefix or suffix, usually three or more characters, that a publisher adds to the names of its objects and of fields it adds to base tables. AppSource publishers register theirs with Microsoft, and AppSourceCop can enforce it in the build.

How do I make my sandbox match production before a release?

Copy production to a sandbox in the Business Central admin center, or refresh an existing one, then download symbols from it and compile and publish there. The app list and versions then match what production runs.

Should I take a dependency on the other app instead?

Only if both apps add the same concept and the other app is stable and staying. A dependency removes the clash and duplicate data entry, but your releases then follow theirs.

Can Solzet fix an extension that will not install in production?

Yes. We reproduce the conflict on a production copy, rename or renumber with your affix, write the upgrade code that moves data, and set up the release checks that catch the next conflict before production.

Which solution is right for your business?

Tell us what you need. A senior consultant replies within one business day with a recommendation (Customer Engagement, Business Central, Finance and Operations, Power Platform or a custom-built CRM), not a sales script.