By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,575 Members | 1,948 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,575 IT Pros & Developers. It's quick & easy.

set password

P: 26
Dear all

can I set a password for each mdf sql database file...or the password for the whole server..

I used the follwoing string


string query = " CREATE DATABASE " + textBox6.Text.ToString() + " ON PRIMARY "
+ " (NAME = " + textBox6.Text.ToString() + ", "
+ " FILENAME = '" + path + "' ,"
+ "Password =" + textBox8.Text.ToString()
+ ") ";

and I got the following error

Invalid usage of the option Password in the CREATE/ALTER DATABASE statement.
Mar 10 '09 #1
Share this Question
Share on Google+
1 Reply


ck9663
Expert 2.5K+
P: 2,878
What are you trying to accomplish?

-- CK
Mar 10 '09 #2

Post your reply

Sign in to post your reply or Sign up for a free account.