1:根據身份證號 更新 生日字段 SQL
update 學生信息 set 生日=substring(身份證號,7,4)+'-'+substring(身份證號,11,2)+'-'+substring(身份證號,13,2) where LEN(身份證號)=18
2:根據身份證號 更新 性別字段 SQL
update 學生信息 set 性別='男' where LEN(身份證號)=18 and substring(身份證號,17,1)%2=1 update 學生信息 set 性別='女' where LEN(身份證號)=18 and substring(身份證號,17,1)%2=0