Wednesday, March 28, 2012

MSDE Setup and first database

I'm deploying MSDE with a desktop app (windows forms .net).
after installing MSDE, how do I create the database for the application?
I cannot provide a createdb.sql script to the user because there is no
queryanalyzer or similar tools.
How can I run the create query from the setup? or what is the recommended
method for doing this?
Thank You!
Hi,
Give a batch file to create the database. All you have to do is double click
the batch file. batch file should contain:-
OSQL -Usa -Ppassword -S servername -Q'Create database
dbname' -o'c:\createdb.log'
Save the command inside a .BAT file and send to client side to create the
database. Instad of giving the -Q parameter you
can also input a .SQL file which contans sequence of TSQL commands.
Thanks
Hari
SQL Server MVP
"Harley" <harleyobrienAThotmailDOTcom> wrote in message
news:E3273FC0-ADE4-47B1-9F3D-8DEC479E3341@.microsoft.com...
> I'm deploying MSDE with a desktop app (windows forms .net).
> after installing MSDE, how do I create the database for the application?
> I cannot provide a createdb.sql script to the user because there is no
> queryanalyzer or similar tools.
> How can I run the create query from the setup? or what is the recommended
> method for doing this?
> Thank You!

No comments:

Post a Comment