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
 General SQL Server Forums
 New to SQL Server Programming
 MDF

Author  Topic 

pjbw
Starting Member

1 Post

Posted - 2012-11-05 : 08:53:23
How do I edit an MDF file?Windows 7.
I have downloaded a 2MB .mdf file, much too big for my needs and I want to edit it.
Google points me to SQL Server Management Studio among other programs.
My W7 has SQL Server and SQL Server Compact Edition.
How do I use one of these to load and then edit my .mdf file?

sunitabeck
Master Smack Fu Yak Hacker

5155 Posts

Posted - 2012-11-05 : 11:47:23
Normally you don't "edit" MDF files in the conventional sense of editing a text file or other document. You use it by attaching the MDF files to a database server. Once you do that successfully, you can inspect the database in SQL Server Management Studio, delete data from tables etc. Then, when you want to move it to a different location or deploy it, you would back up the database from SSMS and restore it at the target server.

I am not familiar with compact edition. You can download and use the Express Edition of SQL 2012 or an earlier version from Microsoft free of charge. Once you install it, you will have access to a local server and mangement studio.
Go to Top of Page
   

- Advertisement -