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

Top 5 Contributors of the Month
Gaurav Pal

Home >> Interview Question >> Sql Server >> Post New Question Subscribe to Interview Questions

Which function is used to know the database property in SQL Server.

Posted By :Abhisek Panda     Posted Date :February 26, 2010    Points :10   Category :Sql Server 

It will return the specified property of the specified database.



You can use this function to know other properties of your database.

You can also find related Interview Question to Which function is used to know the database property in SQL Server.  below: 

Database Concurrency in Sql Server.

When two or more user try to update same type of data in a table then Database Concurrency helps in this situation.

There are 2 types of Database Concurrency

Pessimistic: When one user try to change the data with pessimistic concurrency then a lock is placed on the data in a table so that another user cannot change data. when one user finishes then other user can able to change.

Optimistic: When two user works on the same data in a table and one change that data first then second user cannot change that same data becasue the which he have using is allready changed so he cannot do the change becasue change apply to another data that is changed by first user. (More...)

By Default, ASP.NET does not allow HTML tags to be sent to server via client side due to security reason. Which property needs to be set that allows HTML tags to be processed by server?

ValidateRequest Property needs to be set to false. By default it's true so it does not allow unencoded HTML tags to be processed at server. It can be set at page level or at application level via web.config. (More...)

Which property needs to be set for script manager control to extend the time before throwing time out expection if no response is received from the server?

AsyncPostBackTimeout Property needs to set which gets or sets a value that indicates the time, in seconds, before asynchronous postback time out if no response is received from the server.

The default value of this property is 90 second. We can also set the user defined error message using asyncpostbackerrormessage property (as shown in above code) for time out. (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...)

What is the use of COALESCE function in SQL Server ?

Returns the first not null expression among its arguments.

If X is Null then It'll check for Y,
If Y is Null It'll Check for Z.

Let X is NULL, Y='5' and Z='9'
Here Output is : Y (More...)

Let us say the SQL Server crashed and you are rebuilding the databases including the master database what procedure to you follow?

For restoring the master db we have to stop the SQL Server first and then from command line we can type SQLSERVER -m which will basically bring it into the maintenance mode after which we can restore the master db. (More...)

Which function is used to know the database name by giving the database ID?

The DB_NAME function is used to know the database name. It takes the database id as the argument.


Example:- SELECT DB_NAME(5) -->Student (More...)

Which function performs the opposite function of CEILING function in SQL Server?

FLOOR function performs the opposite function of CEILING function in SQL Server.

FLOOR rounds up a non integer value to the next least integer while CEILING rounds up the non integer values to the next highest integer. (More...)

How will you strink the Database in Sql Server?

We can shrink the Database by connecting to the instance of the SQL
Server and then Expanding the Database and then right click on the
Preferred database and then select tasks then Shrink database.

once you click the "Shrink Database", your database will get shrunk. (More...)

How will you set the compatibility level for your Sql Server Database?

we can set the compatibility level using the below command

for Sql Server 2000:

EXEC sp_dbcmptlevel databasename, 80;

for Sql Server 2005:

EXEC sp_dbcmptlevel databasename, 90;

for Sql Server 2008:

EXEC sp_dbcmptlevel databasename, 100; (More...)

Difference between Len and DataLength function in Sql Server?

LEN() function will not count the trailing spaces.

DATALENGTH() function will count the trailing function


SET @MyString = 'alwyn '
SELECT LEN(@MyString) AS LenFunction


8 (More...)

Write a query to get the second maximum salary using Sql Server 2005 function?


SELECT Salary, RANK() OVER (ORDER BY Salary DESC) AS MaxSalary
FROM dbo.Employee
) a
WHERE MaxSalary = 2

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