Database could not be accessed error

We encountered this error in our staging Environment.

We have multiple staging sites on the server.


Lets say we have, which points to DB1 And Stage.MyCompany.Com/Stage2 points to DB2

Stage.MyCompany.Com/Stage2 works, but Stage.MyCompany.Com gets the “Database could not be accessed” error.

They all use the same App Pool, and all have no issues except for the main staging site.

We know it is not a database issue because if we use switch Stage.MyCompany.Com/Stage2 to use DB1,  it works.   And if we switch Stage.MyCompany.Com to use DB2, it still shows the  “Database could not be accessed” error.

We are using version 2021R1 Version 21.103.0054

Is there way where we can trace what is causing the error?






2 replies

Userlevel 6
Badge +6

Hi @mwong11,

What is the full error message?

Are you using integrated security or SQL Server username/password?

In SQL Server, have you set the proper access rights to the database for the application pool user or SQL user account?

Hi Gabriel,

The error is below.

It is not DB permissions error because we have 2 sites on the same server, using same App Pool, and both using Integrated Security.

Both are on same Acumatica version but with different customizations activated.

The Stage instance points to StageDB database

The Stage/Stage2 instance points to DB1 database

Stage/Stage2 Works with DB1, and If I change it to point to StageDB instead of DB1, it still works.  Because it is using same App Pool and both using Integrated security, I eliminated that it is DB access issue.

But on Stage instance, if I change the DB from StageDB to DB1, it still shows the error “Database could not be accessed” which suggest is not Database permissions issue, but code in Stage issue.  However I do not know how to get additional info to trace the issue.




About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2020  Acumatica, Inc. All rights reserved