MySQL Date Functions

SQL support many functions with which we can manage the dates efectively

Below given are the date functions is MySql

  • NOW()- Returns the current date and time
  • CURDATE()- Returns the current date
  • CURTIME()- Returns the current time
  • DATE()- Extracts the date part of a date or date/time expression
  • EXTRACT()- Returns a single part of a date/time
  • DATE_ADD()- Adds a specified time interval to a date
  • DATE_SUB() -Subtracts a specified time interval from a date
  • DATEDIFF()- Returns the number of days between two dates
  • DATE_FORMAT()- Displays date/time data in different formats
Share