add batch remove batch split batch comment selection show hidden batches hide batch highlight batch
db<>fiddle
donate feedback about
By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'distinct cast(event_date as date) as event_date
from visits' at line 3
event_date user_id
2021-12-22 1
2021-12-23 1
2021-12-24 1
2022-03-10 1
2022-03-11 1
2021-12-23 2
2022-03-12 1
2022-03-13 1
2022-03-14 1
2021-12-25 3
2022-03-15 1
2022-03-20 1
2022-03-21 1
2022-03-23 1
2022-03-24 1
2022-03-25 1
2021-12-30 3
2021-12-31 3
2022-03-21 4
2022-03-22 4
2022-03-23 4
2022-03-24 4
user_id event_date
1 2021-12-22
1 2021-12-23
1 2021-12-24
1 2022-03-10
1 2022-03-11
2 2021-12-23
1 2022-03-12
1 2022-03-13
1 2022-03-14
3 2021-12-25
1 2022-03-15
1 2022-03-20
1 2022-03-21
1 2022-03-23
1 2022-03-24
1 2022-03-25
3 2021-12-30
3 2021-12-31
4 2022-03-21
4 2022-03-22
4 2022-03-23
4 2022-03-24