Powered by Blogger.

Saturday, February 15, 2014

Get database server name in sql server 2008



In this post we will discuss how we can get the database server name in sql server 2008. Also you can check out my previous posts on:

- Get nth highest lowest salary in SQL Server 2008

- Working with enterprise library for data access in asp.net Part-3

- Asp.Net MVC4 Controller class example

Below is the script to get the server name of the sql server 2008:

select @@SERVERNAME As 'Server Name'

Below is the script to get the version of the sql server:

Select @@VERSION As 'SQL Server Version'

The result will come like below:







0 comments

Post a Comment