D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA

databaseName.mdf

databaseName.ldf

在Microsoft SQL Server文件里有保存我们的database record.

上面2个file代表了一个database.

如果我们想快速的把资料和配置搬到一台电脑上,可以copy这2个file

copy 时要先停止 sql 运行

C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Microsoft SQL Server 2012\Configuration Tools\SQL Server Configuration Manager

可以打开这个stop all sql running 才copy.

paste to 另一台电脑的同一个目录下。file 要调permission哦,不然会paste不到的。

之后就开 management studio

左边database right click -> attach -> add -> ok !

Attach file to database的更多相关文章

  1. EF架构~Cannot attach the file as database

    回到目录 Cannot attach the file as database这个异常是在EF的code frist里经常出现的,解决方法很简单,只要重新启动一下V11实例即可. CMD> sq ...

  2. An attempt to attach an auto-named database for file

    在用VS自带的 .mdf读取(joint)时,报错: Server Error in '/' Application. An attempt to attach an auto-named datab ...

  3. Cannot attach the file as database

    Cannot attach the file as database这个异常是在EF的code frist里经常出现的,解决方法很简单,只要重新启动一下V11实例即可. CMD> sqlloca ...

  4. SQL SERVER – Attach mdf file without ldf file in Database

    Background Story: One of my friends recently called up and asked me if I had spare time to look at h ...

  5. Cannot attach the file as database 'membership'.

    Cannot attach the file 'D:\GitHome\cae\CAE\App_Data\membership.mdf' as database 'membership'. 说明: 执行 ...

  6. 异常处理:Cannot attach the file as database 'membership'.

    Cannot attach the file 'D:\GitHome\cae\CAE\App_Data\membership.mdf' as database 'membership'. 说明: 执行 ...

  7. Logging - MVC Using Log4net Save to File and Database

    第一步:创建Config文件夹和log4net.config 第二步:在log4net.confg黏贴以下配置 <?xml version="1.0" encoding=&q ...

  8. Checklist For Choosing The Right Database Engine

    http://sqlite.org/whentouse.html Appropriate Uses For SQLite SQLite is not directly comparable to cl ...

  9. I/O requests taking longer than 15 seconds to complete on file I/O瓶颈问题

    I/O requests taking longer than 15 seconds to complete on file I/O瓶颈问题 http://mssqlwiki.com/2012/08/ ...

随机推荐

  1. windows下的类似grep命令findstr

    windows下的类似grep命令findstr findstr后面跟的字符串不能加引号 C:\Users\Administrator>netstat -an|findstr 10.1.151 ...

  2. UITextView ios7

    UITextView *textView2 = [[UITextView alloc]initWithFrame:CGRectMake(, textView1.frame.size.height + ...

  3. 将activity设置成dialog样式如何设置窗口大小

    具体做法和dialog窗口的设置类似,只需要在onCreate方法中,加入下列代码,既可以控制大小! // 设置窗体大小  ScreenUtil.getScreenWidth(LoadActivity ...

  4. PHP5.4的变化关注---What has changed in PHP 5.4.x(转)

    What has changed in PHP 5.4.x Most improvements in PHP 5.4.x have no impact on existing code. There ...

  5. MySQL(12):windows下解决mysql忘记密码

    mysql有时候忘记密码了怎么办?我给出案例和说明!一下就解决了!    Windows下的实际操作如下 : 1. 关闭正在运行的MySQL.  2. 打开DOS窗口,转到mysql\bin目录. 3 ...

  6. DELL RACADM 批量升级戴尔IDRAC固件

    需求:通过服务器远程管理IP批量升级戴尔IDRAC固件 工具:racadm.ipmitool.Remote Access Configuration Tool 下载: 第一步,将要更新BMC IP写入 ...

  7. mvc和webapi同一解决方案调试办法

    今天在研究WebApi的时候,用mvc端直接请求webapi接口,发现怎么也请求不了,自己搞了半天,猜测可能是webapi没有完全启动吧,解决办法是将解决方案属性改为多启动项目,具体方法如下: 直接运 ...

  8. 在C#中internal关键字是什么意思?和protected internal区别

    我来补充一下,对于一些大型的项目,通常由很多个DLL文件组成,引用了这些DLL,就能访问DLL里面的类和类里面的方法.比如,你写了一个记录日志的DLL,任何项目只要引用此DLL就能实现记录日志的功能, ...

  9. 学习日记-----ORM

    ORM ORM(Object Relation Mapping)对象关系映射 实质:将数据库中 的业务数据用对象的形式表现出来,使用ORM在业务逻辑层和数据访问层之间充当桥梁 核心原则: 简单性 传达 ...

  10. Eclipse 导入项目乱码问题(中文乱码)

    1.编码不对 a.对某文件或某工程更改编码:   鼠标移到工程名或文件名,右键->Properties->Resource->Text file enCoding ->更改编码 ...