Hi everyone
i wonder if there is a way to create a table in sql2000 database from an asp.net application?
please anyone can help?
Thanks
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Mahesh ChandPosted Aug 2, 2005, 10:57 AM
trufun101Posted Aug 2, 2005, 10:52 AM
SqlConnection sqlConn = new SqlConnection(strSqlConnection);
string strSql = "CREATE TABLE ... ";
SqlCommand sqlCmd = new SqlCommand(strSql, sqlConn);
sqlCmd.Connection.Open();
sqlCmd.ExecuteNonQuery();
sqlCmd.Connection.Close();
That should work.