SQL Error while Opening the DB

st0328st0328 Member Posts: 97
Hi all,

when we are trying to open the DB.
An SQL error is coming while opening the DB .

NAV Veriosn : R2
DB : SQL
OS : WIN SERVER R2



Microsoft Dynamics NAV Classic
The following SQL Server error or errors occurred:

924,"42000",[Microsoft][ODBC SQL Server Driver][SQL Server]Database 'Live_04-03-13' is already open and can only have one user at a time.

SQL:
SELECT COUNT(*), SP.[program_name] FROM [master].[dbo].[sysprocesses] AS SP WHERE SP.[ecid] = 0 AND SP.[context_info] = 0x01 AND SP.[last_batch] >= CONVERT(DATETIME, '2000-01-01 00:00:00', 120) AND SP.[program_name] IN ('Microsoft Dynamics NAV Classic client','C/ODBC','C/FRONT','Application Server for Microsoft Dynamics NAV Classic','VIP Application Server for Microsoft Dynamics NAV Classic','Microsoft Dynamics NAV RTC') GROUP BY SP.[program_name]

OK


Please Suggest me in this

Answers

  • Marije_BrummelMarije_Brummel Member, Moderators Design Patterns Posts: 4,262
  • postsauravpostsaurav Member Posts: 708
    Hi,

    Just check the property in SQL.

    Open SQL Server.
    Right click the database and select properties.
    Click on Options form Left hand panel.
    Drill down to end of the page and check last property value (Restrict Access).
    If the value is SINGLE_USER change it to MULTI_USER and try again.

    Let me know if any issues.

    Thanks & Regards,
    Saurav Dhyani

    Do you Know this About NAV?


    Connect - Twitter | Facebook | Google + | YouTube

    Follow - Blog | Facebook Page | Google + Page
  • st0328st0328 Member Posts: 97
    Hi,

    thanks for Quick reply and suggestions..

    In the same server we have another DB which is of Single User Mode. But,the DB we are trying to open is not in Single User Mode.

    After this error, we tried to change the that DB to Multi User Mode which was in Single User Mode . But, it is not allowing to change. And we are getting the same Error.

    Please suggest
  • Marije_BrummelMarije_Brummel Member, Moderators Design Patterns Posts: 4,262
    The database is in use by a process. Hence the single user is used.

    To change the property the database must be unused.

    Usually what helps is restarting SQL Server and make sure SQL agent is not running.

    If you're quick enough you should be able to change the property.
  • st0328st0328 Member Posts: 97
    thanks for Suggestions Mark Brummel & postsaurav :)

    we found the user and ask him to close the DB and Deleted all the users of the DB which was in Single user Mode and Changed to Multi User Mode

    Now it is opening..
    Resolved.
Sign In or Register to comment.