Here is my query and it's giving SQL manual syntax error in MySql.
select
count(case when v.created_at = vv.minva then user_id) as num_new_users
from bills v
join (select user_id, min(created_at) as minva from bills t group by user_id ) vv
on v.user_id = vv.user_id
Can someone please help me with the problem?