mysql 截取身份证出生日期

select idno as 身份证号, cast(substring(idNo,7,8) as date) as 出生日期, DATE_FORMAT(cast(substring(idNo,7,8) as date), '%m-%d') as 生日  from t_person

posted on 2017-01-04 16:41  Ruthless  阅读(8140)  评论(1编辑  收藏  举报