SELECT
DATEPART(yy , GETDATE()) AS Jahr
, DATEPART(qq , GETDATE()) AS Quartal
, DATEPART(mm , GETDATE()) AS Monat
, DATEPART(dd , GETDATE()) AS Tag
, DATEPART(hh , GETDATE()) AS Stunden
, DATEPART(mi , GETDATE()) AS Minuten
, DATEPART(ss , GETDATE()) AS Sekunden
, DATEPART(ms , GETDATE()) AS Millisekunden
, DATEPART(wk , GETDATE()) AS Woche
Jahr Quartal Monat Tag Stunden Minuten Sekunden Millisekunden Woche
--------- --------- --------- --------- --------- --------- --------- ------------- -----
2004 2 6 23 11 23 59 513 26
(1 row(s) affected)
Weitere Informationen stehen in BOL.