Skip to main content

Notifications

Small and medium business | Business Central, N...
Suggested answer

Extension compilation failed Codeunit.al(11,25): error AL0132: 'Record Contact/Customer/Vendor' does not contain a definition for 'Custom field'

Posted on by Microsoft Employee

I'm trying to publish a new 1.0.0.2 version to a previously released 1.0.0.0 extension (which has been uninstalled).

I use this script in Dynamics Nav Administration shell:

...
Publish-NAVApp -ServerInstance $ServiceInstance -Path "<app path>.app" -SkipVerification -PassThru
Install-NAVApp -ServerInstance $ServiceInstance -Name '<app name>'

This fails because 'Record Contact/Customer/Vendor' does not contain a definition for 50200 'Custom field'.


This custom field 50200 has been added using the Navision Development environment (it is visible and when I run the table there, it does contain data).

The setup is a solution of which one part has been developed in the development environment and another part is an extension (those two are functionally different).
They run on a BC11 service.

After some googling, I found this:
https://tabrezblog.azurewebsites.net/post/2020/04/01/publish-navapp-extension-compilation-failed-during-publishing-extension-in-on-on-premises-business-central-production-environment
So I run this finsql command:
cd "C:\Program Files (x86)\Microsoft Dynamics NAV\110\RoleTailored Client"
finsql.exe Command=generatesymbolreference, Database="<Database>", Servername="<Database Name>\<Database Instance>"

I get the following output in the error log under ...\RoleTailored Client:

"[22926090] The Object Metadata table cannot be changed because it is locked by another user. This can be caused by one of the following tasks: * Objects are being compiled. * Table schema is synchronizing. * Objects are being imported. Wait until the user is finished and then try again."

The above happens even when I restart both services (the client and webservice service).

At some point, running the finsql command seemed to be succesful ([0] [04/01/21 14:35:04] The command completed successfully in '348' seconds.) but even then, I was unable to publish the app because of those 'Custom Field's not being defined in those tables.

I really need to publish this app.
Any help would be greatly appreciated.

  • Suggested answer
    THE Italian Profile Picture
    THE Italian on at
    RE: Extension compilation failed Codeunit.al(11,25): error AL0132: 'Record Contact/Customer/Vendor' does not contain a definition for 'Custom field'

    You have not the right symbols in place or the application version is not correct.

    I would encourage you in be in touch with your CSP Partner and have them open a support request to Microsoft in order to help you in recreating symbols appropriately or validate that you have the right symbols in place (application, system and test). NOTE: tenantdataversion from get-navtenant command must match the application symbol version.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Extension compilation failed Codeunit.al(11,25): error AL0132: 'Record Contact/Customer/Vendor' does not contain a definition for 'Custom field'

    Thank you, Suresh

    This certainly helped me one step further, however, now upon Publish-NAVApp, I get an error 'Your program license does not allow you to publish 'SomeExtensionObject'.

    This is within range as v1.0.0.0 which was installed already had this extension object.

    We tried your setting AND running finsql generatesymbols command (which completed succesfully) but to no avail.

    Last, I tried the following:

    Upload dev license on our TEST service tier (and of course restart this service).

    Publish-NAVApp

    Upload the client license again.

    This last step, however, led to new errors (The name 'Rec' does not exist can be ignored in my opinion as this is a deprecation I fixed but the business central i'm trying to publish to is v11):

    pastedimage1609846191151v1.png

    Any (further) help would be greatly appreciated.

  • Suggested answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Extension compilation failed Codeunit.al(11,25): error AL0132: 'Record Contact/Customer/Vendor' does not contain a definition for 'Custom field'

    I am thinking you don't have any problems publishing this app in your local docker container correct? are you running BC or NAV, if you have added any code or fields using NAV Development Environment, you need to make sure you on the Admin "Enable Loading Application Symbols at server startup"

    Please refer to these links

    https://docs.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/devenv-running-cside-and-al-side-by-side

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans