Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 .NET Inside SQL Server (2005)
 attach and detach my mdf file programatically T.SQ

Author  Topic 

elmasrya1
Starting Member

3 Posts

Posted - 2008-06-09 : 08:48:42
Hello Professionals, How can i attach and detach my mdf file to an instanse of sql 2005 programatically or by T-SQL

ElmasryA1

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-06-09 : 13:29:37
Check out sp_detach_db, sp_attach_db, and sp_attach_single_file_db in SQL Server Books Online.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page
   

- Advertisement -