先用to_date将字符串转换成时间格式,再用to_char截取指定的yyyyy年MM月dd日 select to_char(to_date('2002-08-26','yyyy-mm-dd'),'MM') from dual