如何在SQLSERVER中将我的aspnetDB.mdf与我自己的数据库一起使用 [英] how to use my aspnetDB.mdf with my own database in SQLSERVER

查看:119
本文介绍了如何在SQLSERVER中将我的aspnetDB.mdf与我自己的数据库一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

aspnetDB.mdf文件数据库非常适合用户管理。我想用它自己的数据库这可能吗?我如何关联(将aspnetdb和我的owndb结合)到一个数据库。 aspnetDb.mdf是SQLSERVER中的一个文件和我自己的数据库。

aspnetDB.mdf file database is really good for user management. I want to use it with my own database is this possible?? how can i associate(Combine aspnetdb and my owndb) to one database. aspnetDb.mdf is a file and my own db in SQLSERVER.

推荐答案

我认为这可能会帮助你更接近



附加数据库



在SQL Server Management Studio对象资源管理器中,连接到SQL Server数据库引擎的实例,然后展开该实例。



右键单击数据库,然后单击附加。



在附加数据库对话框中,指定要附加的数据库,单击添加;在定位数据库文件对话框中,选择数据库所在的磁盘驱动器,然后展开目录树以查找并选择数据库的.mdf文件;例如:



I think this may help you to get nearer

To Attach a Database

In SQL Server Management Studio Object Explorer, connect to an instance of the SQL Server Database Engine, and then expand that instance.

Right-click Databases and click Attach.

In the Attach Databases dialog box, to specify the database to be attached, click Add; and in the Locate Database Files dialog box, select the disk drive where the database resides and expand the directory tree to find and select the .mdf file of the database; for example:

C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\AdventureWorks2012_Data.mdf





这里是更详细的说明链接...

http://msdn.microsoft.com/en-us/library/ms190209.aspx [ ^ ]


这篇关于如何在SQLSERVER中将我的aspnetDB.mdf与我自己的数据库一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆