cast date to format month day year in sql code example Example: sql convert datetime to year month DATE_FORMAT(_column, '%Y-%m')AS `yyyy-mm`,