SQL Server Error 5123 When Attaching Database

Kevin Jones picture Kevin Jones · Jun 8, 2018 · Viewed 7.7k times · Source

I have two databases. Both are in the same folder. Both have, as far as I can tell, the exact same ownership and permissions. I can attach one but not the other - I get an error 5123.

For both files...

  • Owner is MSSQLSERVER

Permission entries:

  • MSSQLSERVER - Full control

  • OWNER RIGHTS - Full control

  • Administrators - Full control

I reviewed the other question referenced below but could not get any of the suggestions to work given my constraints listed above. I posted what finally worked below.

Answer

seraj picture seraj · Jul 25, 2020

Add your User to Permissions:

[your user] - full control  

MSSQLSERVER - Full control

OWNER RIGHTS - Full control

Administrators - Full control