使用SQL语句:SELECT CONCAT(fieldA,fieldB,fieldC) as combinedFields, COUNT(DISTINCT combinedFields) as count FROM test GROUP BY combinedFields;此语句先使用CONCAT函数拼接字段A,B,C为一个组合字段com...
– 在支持窗口函数的SQL中使用 select count(case when rn=1 then task_id else null end) task_num from (select task_id , row_number() over (partition by task_id order by start_time) rn f...