查询2020年的数据:

 select * from day_rate where year(时间字段)='2020' 

查询2月份的数据:

select * from day_rate where month(时间字段)='02'

查询2020年2月份的数据:

select * from day_rate where year(时间字段)='2019' and month(时间字段)='02'

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2022-02-07
  • 2022-12-23
  • 2022-12-23
  • 2021-06-26
  • 2021-12-10
猜你喜欢
  • 2021-12-06
  • 2022-12-23
  • 2021-05-11
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案