Hello,
Our product has a MDF file included with the setup, this needs to be attached at the current SQL Server (Express or not).
Where can we copy the MDF file during setup so it can be attached successfully
Please help !
Thanks
SQL Server Security
You can always use CREATE DATABASE mydb ON ( FILENAME = 'mydb.mdf')
to attach a database after installing sql server.
refer to http://msdn2.microsoft.com/en-us/library/aa258257(SQL.80).aspx for more details.
or you can do attach database via management studio
Look into this link: http://msdn2.microsoft.com/en-us/library/ms190209.aspx
Embedded database feature is only available in SQL Server Express. In express, in connection string you can mention UserInstance and attach mdf file. But in all other versions, you will have to attach the database using some sqlscript explicitly. And also connection string will differ in both method
Refer this link for userinstance :
Madhu