devxlogo

Using the SQL FORMAT Function

Using the SQL FORMAT Function

The SQL FORMAT() function is used to format how a field should be displayed. You can format dates in a column in the following manner:

SELECT FullNames, Surname, UserID, FORMAT(Now(),'YYYY-MM-DD') AS LoggedInDateFROM Users;

devx-admin

Share the Post: