Logo 
Search:

SQL Server Articles

Submit Article
Home » Articles » SQL Server » System FunctionsRSS Feeds

HOST_NAME Function

Posted By: Sarita Patel     Category: SQL Server     Views: 1909

This article explains about HOST_NAME function in sql server with examples.

HOST_NAME function returns workstation workstation name.


Syntax of HOST_NAME Function :

HOST_NAME ( )

Return type of HOST_NAME function is a nchar. 




Examples of HOST_NAME Function :

Example 1 : Use of HOST_NAME function in select clause 

SELECT HOST_NAME ( )

Output
Northwind-PC

Above example returns workstation name of computers.
  
Share: 

 
 

Didn't find what you were looking for? Find more on HOST_NAME Function Or get search suggestion and latest updates.

Sarita Patel
Sarita Patel author of HOST_NAME Function is from United States.
 
View All Articles

Related Articles and Code:


 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
No Comment Found, Be the First to post comment!