I would need to create a program that only install SQL Express and install a database at the same time (either from a bak or mdf, whichever is prefered) At the end of the creation, this program would generate a text file.
I found on the web how to install SQL Express, but I can’t seem to find anything to add a database after the installation.
So far I don’t have anything to install else than that because the application that will use the application will be installed on another machine.
Thanks
One simple way would be to make a simple batch file, with a line to run the SQL Express command line install and then the next to run
sqlcmdto do the restore.How to: Install SQL Server 2008 R2 from the Command Prompt
Backup and Restore Your SQL Server Database from the Command Line
If you want to make your life easier then use some kind of installer tool. I have used Advanced Installer, InstallAware, and InstallShield at various times to do this.