web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Answered

An unexpected error occurred after a database command was cancelled.

(0) ShareShare
ReportReport
Posted on by 151

unexpected-error.png

I was trying to import license then I was getting this error any body knows how to resolve this.

"An unexpected error occurred after a database command was cancelled."

Thanks in Advance

I have the same question (0)
  • Suggested answer
    howeidat Profile Picture
    35 on at
    RE: An unexpected error occurred after a database command was cancelled.

    Hello

    1- make sure that NAV/BC service is in running mode.

    2- run the Administration Shell in administrator mode.

    3-make sure that you input the instance name correctly.

  • Suggested answer
    Jeffrey Bulanadi Profile Picture
    8,433 on at
    RE: An unexpected error occurred after a database command was cancelled.

    Hi Salba,

     

    In addition to the above suggestion,

     

    Have you tried accessing first NAV/BC on-prem? You should have a valid user as well.

  • Suggested answer
    YUN ZHU Profile Picture
    93,438 Super User 2025 Season 2 on at
    RE: An unexpected error occurred after a database command was cancelled.

    Hi, just adding some info. You can view more error info in Event -> Windows Log.

    Hope this helps.

    Thanks.

    ZHU

  • Salba Z.K Profile Picture
    151 on at
    RE: An unexpected error occurred after a database command was cancelled.

    hi sir

    this is a problem

    in event viewer Invalid object name 'master.dbo.$ndo$srvproperty'"

  • Suggested answer
    Nitin Verma Profile Picture
    21,696 Moderator on at
    RE: An unexpected error occurred after a database command was cancelled.

    Hi,

    Please check if you have access master DB permission, go to SQL Server, click on appropriate User login > Property and select Master DB, see the image below.

    pastedimage1660206860120v1.png

  • Rebe.Gwaindepy Profile Picture
    178 on at
    RE: An unexpected error occurred after a database command was cancelled.

    Hi, i had this problem when restored a Demo database from SSMS rather than using the one using on installing BC or installing BC. Aparently there are some tables BC installer creates for the license and your admin shell cant find them. There is a workaround of running a query to create those tables but it did not work well for me, i had to use the BC db uninstalling Database components and reinstall with installer.

    i hope this helps.

    Regards,

  • Verified answer
    Rebe.Gwaindepy Profile Picture
    178 on at
    RE: An unexpected error occurred after a database command was cancelled.

    try running this query on the Master DB:

    USE [master]

    GO

    CREATE TABLE [dbo].[$ndo$srvproperty](

    [license] [image] NULL

    ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

    GO

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
Rishabh Kanaskar Profile Picture

Rishabh Kanaskar 2,568

#2
Sumit Singh Profile Picture

Sumit Singh 2,536

#3
YUN ZHU Profile Picture

YUN ZHU 2,015 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans