sqlserver查询当月数据

SELECT * FROM table WHERE datediff(month,LoginTime,getdate())=0 ORDER BY LoginTime

SELECT * FROM table WHERE datediff(month,ApproveTime,getdate())=0 ORDER BY ApproveTime

原文地址:https://www.cnblogs.com/furenjian/p/10185958.html