Group by Day in Bar Graph

I am trying to group data by day.

For example, to show a bar graph per day with the number of emails sent per day.
I don’t want to hard code the group by value, since it will depend really if the in the time picker i chose 7 days, or 30 days, or…

When I leave the default group by $__interval value, it used strange numbers, like 2h for a 7 day period.

And even if I hard code the graph, with a static group period, when I try to change the timepicker it changes the X Axis of the graphs and messes up the display. So I couldn’t even show 7 days and 30 days as two separate graphs. I find the interval value affects the data, but NOT the X Axis dates.