Query 1:
SELECT id,COUNT(X.C_NO) as count
FROM table X
WHERE X.date = '2022-02-02'
and P_NO is not null
group by id;
Query 2:
SELECT id,
sum(CASE WHEN C_NO IS NOT NULL and P_NO is not null THEN 1 ELSE 0 END) as count
FROM table X
WHERE B.date = '2022-02-02'
group by id;
Just wanted to know if both of these queries would produce the same results or different results
