Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What command do we use to rename a db?

Answers were Sorted based on User's Feedback



What command do we use to rename a db?..

Answer / visala

sp_renamedb 'oldname','newname'

alter database <databasename>
modify name=<newdatabasename>

Is This Answer Correct ?    17 Yes 0 No

What command do we use to rename a db?..

Answer / swetha

sp_renamedb ?oldname? , ?newname?

alter database ?databasename?
modify name = ?newdatabasename?

Is This Answer Correct ?    7 Yes 0 No

What command do we use to rename a db?..

Answer / latha sree

sp_renamedb ?oldname? , ?newname?

Is This Answer Correct ?    7 Yes 1 No

What command do we use to rename a db?..

Answer / karthick.r

sp_rename olddatabasename newdatabasename
for eg
sp_rename prodetails empdetails;


in this eg the name of the prodetails is changed into
empdetails using above command

Is This Answer Correct ?    2 Yes 1 No

What command do we use to rename a db?..

Answer / babuli

To rename a SQL database follow the these seps:

1. Alter database to single user mode. So that all the
active connection will be terminated. (Database properties
-> options > single usermode)
2. Then rename the database using sp_renamedb oldname, newname

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More SQL Server Interview Questions

Why we use trigger in sql server with example?

0 Answers  


what is a self join? Explain it with an example? : Sql server database administration

0 Answers  


What is history table in sql server?

0 Answers  


What are the different methods available under sqlcommand class to access the data?

0 Answers   UGC Corporation,


How can you list all the columns in a database?

0 Answers  


What is the template in sql?

0 Answers  


What are the different ways you can create databases in sql server?

0 Answers  


What are tasks?

3 Answers   Wipro,


Why use sub query in sql server and list out types of sub queries?

0 Answers  


What is cte (common table expression)?

0 Answers  


How to drop an existing user defined function in ms sql server?

0 Answers  


What is the maximum size of sql server database?

0 Answers  


Categories