show-notice
hide-notice

Tuesday, 6 August 2013

FORMAT() Function in Sql Server


Introduction:
The FORMAT() function is used to format how a field is to be displayed.


Syntax:
SELECT FORMAT(column_name,format) FROM table_name;

Example:
SELECT ProductName, Price, FORMAT(Now(),'YYYY-MM-DD') AS PerDate
FROM Products; 

SHARE THIS POST   

0 comments :

Post a Comment

Design by Gohilinfotech | www.gohilinfotech.blogspot.com