sql get year from datetime field code example Example: sql get year from datetime field SELECT YEAR(DateTimeField) FROM MyTable