sql根据出生日期计算年龄

使用DATEDIFF()函数

select DATEDIFF(year,age,GETDATE()) Age from table

原文地址:https://www.cnblogs.com/blog4xy/p/3977250.html