Create database from mdf file
CREATE DATABASE your_database_name ON PRIMARY (FILENAME = 'C:\dat.mdf') FOR ATTACH GO drop database your_database_name GO