没想到Attach数据库的时候出现如下错误: <br/>Operating system error 5: "5(failed to retrieve text for this error. Reason: 15105)". (Microsoft SQL Server, Error: 5120)<br/> 我搜索了一下错误号码,找到如下解决方案,并照做了,但又出现新的错误如下图。 <br/>解决办法: <br/>1、打开该数据库文...
Let us now look at the possible solutions to fix this error. How to fix SQL error 5120? As we discussed earlier, the primary reason for this error message is insufficient permission to attach or detach the database. Thus the method to fix it include changing the permission of the file or...
copy your both mdf and ldf files to the default database folder of the sql server edition. for 2010 express edition u need to copy it to C:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA\. Then try to attach the db, it may work. ...
使用以下命令拆离数据库。 SQL 复制 exec sp_detach_db DatabaseName go 使用以下命令重新附加数据库。 SQL 复制 exec sp_attach_db DatabaseName, '\\Network-attached storage_Path\DatabaseMDFFile.mdf', '\\Network-attached storage_Path\DatabaseLDFFile.ldf' go 反馈...
今天用SQL Server 2008的attach功能附加一个数据库,出了点问题,提示的错误是: 复制 Unable to open physical file "D:\Documents\Dalt\XXXX.mdf" Operating system error 5: "5(error not found)" (Microsoft SQL Server: Error 5120)". 1. 记得以前做过类似的操作没有出现什么问题的,不知道为什么会这样,...
and i get an error message says . Attach database failed for server 'SMSM-PC'. (Microsoft.SqlServer.Smo) Additional information: An exception occurred while executing a Transact-SQL statement or batch (Microsoft.SqlServer.ConnectionInfo) Unable to open the physical file "D:\...\...\nort...
今天用SQL Server 2008的attach功能附加一个数据库,出了点问题,提示的错误是: Unable to open physical file "D:\Documents\Dalt\XXXX.mdf" Operating system error 5: "5(error not found)" (Microsoft SQL Server: Error 5120)". 记得以前做过类似的操作没有出现什么问题的,不知道为什么会这样,没办法在网...
网上查了一下,出现这种错误(错误5120),很可能是因为权限问题,即我们现在的这个账户没有足够的权限来附加此数据库。那么下面这几种方法可以轻松地解决这个问题: 1、将要附加的文件拷贝到SQL Server默认的Data 目录(C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA),再次附加就会成功。
( FILENAME = N'E:\Program Files\Microsoft SQL Server\MSSQL\Data\mydbname.ldf' ) FOR ATTACH; this method does not work - "could not open new database "database_name" - create database aborted. An error occured while processing the log for database 'mydb'. if possible, restore from...
Could not open new database 'Dotnet67'. CREATE DATABASE is aborted. (Microsoft SQL Server, Error: 5118) 把数据文件的属性的compress选项的勾去掉就可以解决。 Basically I wanted to keep the db file on a drive other than the default operating system drive. But as my other drives are compressed...