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;
Share the Post:
Share on facebook
Share on twitter
Share on linkedin

Related Posts