Skip to main content
Question

Bar Chart by the Hour

  • March 26, 2019
  • 0 replies
  • 23 views

I wish to create a bar chart showing the number of orders taken today by the hour e.g 8-9, 9-10, 10-11 and so on.

Is this possible. The group by box doesn't seem to offer time based options?

I have fixed this by creating an new field which converts date created to the hour and grouping by equal value..

This topic has been closed for replies.

np
just make for your own text formula field or time of day formula field to bucket the ties by hour, and then group on equal values.

If you use a formula text field you will need to contrive to have them list in alpha sequence to ensure that 9:00 am is before 1;00 pm., so you may need to ad a leading space.

for example

var TimeOfDay Time = ToTimeOfDay([my date / time field]);

IF(
$Time < ToTimeOfDay("7:00 am"), "   Before 7:00 am",
$Time < ToTimeOfDay("8:00 am"), "  7-8" ,
$Time < ToTimeOfDay("9:00 am"), "  8-9" ,
etc

$Time < ToTimeOfDay("1:00 pm"), " 12-1" ,
$Time < ToTimeOfDay("2:00 pm"), "1-2" ,
$Time < ToTimeOfDay("3:00 pm"), "2-3" ,

etc

)