.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Interview Question >> Others >> Post New Question Subscribe to Interview Questions

State the command that is used to rename a database?

Posted By :shankey     Posted Date :July 31, 2011    Points :40   Category :Others 
sp_renamedb 'OldDbName','NewDbName'

You can also find related Interview Question to State the command that is used to rename a database?  below: 

State command to rename a table?

  
sp_rename 'oldTableName' , 'NewTableName' (More...)

Name of the command to view the current amount of free (unallocated) space in the database in SQL Server?

  
Name of command is :sp_spaceused

This command displays the database_size in MB, and it's also shows unallocated space for the database. (More...)

How to rename a database in SQLserver?

  
using the procedure sp_renamedb. Following is the syntax

Exec sp_renamedb 'olddbname','newdbname' (More...)

What command do we use to rename a db?

  
sp_renamedb 'oldname' , 'newname'
If someone is using db it will not accept sp_renmaedb. In that case first bring db to single user using sp_dboptions. Use sp_renamedb to rename database. Use sp_dboptions to bring database to multi user mode. (More...)

Database should be created as a SINGLE_USER state Whenever you create a new Database. What should you do ?

  
1. Normally, when we create a new database, All the properties will be inherited from the Model database.

2. So, Just change the Model database's State to SINGLE_USER.

3. Now onwards, The new database will be created as SINGLE_USER state. (More...)

Database: State whether Trigger is a stored procedure or not?

  
.Yes, It is a Stored procedure that initiates an action when an event occurs. (More...)

Database: State whether a trigger can be called or executed?

  
.No, It is called by DBMS automatically whenever any changes are made to the associated table. (More...)

Database: state whether function and Views are similar in some respect?

  
Yes, Function take parameters and can be used in joins and other row set operations. (More...)

Database: State Can an Identity column be index?

  
No, Identity and GUID column do not need to be indexed. (More...)

Database:State whether the TCP/IP port can be changed on which SQL Server run

  
Yes, It can be changed from
1)Network utility TCP/IP properties
2)Port number, both on client and server (More...)

Quick Links For Interview Questions Categories:
ASP.Net Windows Application   .NET Framework   C#   VB.Net   ADO.Net  
Sql Server   SharePoint   Silverlight   OOPs   JQuery   JavaScript/VBScript
Biztalk Patten/Practices .IIS WCF WPF WWF
Networking Aptitude Others   All      

Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.

 
Now you can find lots of .NET, C#, Vb.Net, SQL Server,Windows, ASP.Net related Questions and their Answers here at www.dotnetspark.com. Our aim is to help you pass your certification Exams (MCP, MCSD, MCAD etc.,) with flying scores and get good name in your company.

So, Start looking our Interview Question section daily and improve your .NET Skills. You can also help others by posting Interview Questions and their Answers in this section.


Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend