查询员工是否有入职满三年 sql

<select id="selctBeanInfo" resultType="com.cn.UserInfo"
            parameterType="java.lang.Integer">
        select *
        from user_info
        where status = 0
        and TIMESTAMPDIFF(DAY,date_add(add_time, interval 3 YEAR),NOW())>= 0
    </select>

  

原文地址:https://www.cnblogs.com/xianz666/p/15355225.html