SQL中如何查询某个表中某个字段在一定时间差内出现的重复数据以及重复的次数

2024-11-29 00:43:23
推荐回答(1个)
回答1:

你时间差需要有一个字段记录时间,假设叫time

select distinct(column_name),count(1) as num from table_name where time between time1 and time2 having num > 1 order by num