Dear All,
I am writing a script for SQL6.5 for auto generating a database and a user for that database and few tables within the database.
I am struck at changing the user from 'sa' to the newly created user (say 'sharan') so that i can create a database and table under him.
In Oracle I can use a command in SQL script file for this as "connect sharan/abcd123" but how to do in SQL server?
Presently, I am changing the ownership from SA to sharan after creating the database and tables.But, still the owner would be DBA not sharan for database and tables.
Can you please help me? Thanks in advance.
Thanx n Rds