top of page

Some basic queries In SQL Server

1. Retrieve List of All Database



EXEC sp_helpdb 

ree
List of All Database

2. Get the version name of SQL Server

SELECT @@VERSION AS Version_Name  

ree
Server Version

3. Get Current Language of SQL Server

ree

4. Return Server Name of SQL Server.

SELECT @@SERVERNAME AS 'Server_Name'

ree
Server Name

5, Retrieve Free Space of Hard Disk.

EXEC master..xp_fixeddrives 

ree
Free Space

6. Get First Date of Current Month

SELECT CONVERT(VARCHAR(25),DATEADD(DAY,-(DAY(GETDATE()))+1,GETDATE()),105) First_Date_Current_Month;

ree

Need any help in SqlServer Please contact us


If you like Codersarts blog and looking for Assignment help,Project help, Programming tutors help and suggestion you can send mail at contact@codersarts.com.

Please write your suggestion in comment section below if you find anything incorrect in this blog post

 
 
 

Comentarios


bottom of page