MINUTE

From SQLZoo
Jump to navigation Jump to search
Compatibility
MINUTE(d)
EngineOKAlternative
ingresNoEXTRACT(DAY from d)
mysqlYesEXTRACT(DAY from d)
oracleNoTO_CHAR(d,'DD')
postgresNoEXTRACT(DAY from d)
sqlserverYesDATEPART(DAY,d)

MINUTE

MINUTE allows you to retrieve the minute from a date.

   MINUTE(d)

In this example you get the minute from the date field whn.

SELECT EXTRACT(MONTH from whn) AS v
      ,whn
      ,wht
  FROM eclipse
SELECT EXTRACT(MONTH from whn) AS v
      ,whn
      ,wht
  FROM eclipse
SELECT TO_CHAR(whn,'MONTH') AS v
      ,whn
      ,wht
  FROM gisq.eclipse
SELECT MINUTE(whn) AS v, whn, wht
  FROM eclipse

See also

Language:Project:Language policy English  • Deutsch
DataWars, Data Science Practice Projects - LogoDataWars: Practice Data Science/Analysis with +100 Real Life Projects