Troubleshooting Error: Cannot open database requested by the login.

Here is one of the errors I encountered while I was working in Dynamics AX 2012. The complete error message is:

Cannot open database requested by the login. The login failed.Login failed for user ‘NT AUTHORITYNETWORK SERVICE’.

This error normally occurs when the application has been configured with the IIS and IIS does not have proper credentials to access SQL.

Here is a quick solution to solve this error. Open SQL Server Management Studio and go to the Security->Logins and right click on NT AUTHORITYNETWORK SERVICE.Right click on it and select Properties. A new screen will appear. Go to “User Mapping” and select your desired database. In the Database role memberships, tick the “db_owner” checkbox. Click Ok and restart your AX service.

About the author

Fatima Zafar is an Associate Software Engineer in the Dynamics Team at Systems Limited. She is extremely passionate about her work and loves to explore development platforms and tools. As a technology oriented person, she has under her belt a wide range of experiences including technical writing, tutorial development and blogging for technology and has dabbled (significantly well) with X++, .NET and MySQL. Currently working as a Microsoft Dynamics AX developer, she aims to explore as many areas of Dynamics as she can. Other than AX, her passions include graphic designing and she would like to work more on that front as well.

Leave a Comment

Name (required)
Email (required)
Comment (required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>