Sales Per Hour Report

Hallo everybody.
I have the report for sales per hour using script.
Can you please tell Me how to make this report with Custom Report Tags?
It’s should be something like this

@gerlandog @QMcKay @Jesse @emre Anybody?

oooh… how’d u get report by hour?! this is something I’ve missed?


1 Like

He used SQL. To do it solely with Report Tags I had to use Ticket Tags to mark the points in the day for it to track but that was quite a while ago. We have a lot more tags available I will look into it and see if anything new is possible. If its working with SQL what is reason for switching to just Report Tags?

What would be great is option to make Ticket Tags hidden otherwise if you made a tag for every hour during your day the ticket might get a little cluttered lol.

Out of interest on a report like this, is it based on order time level or say ticket payment/final close time (or just depends on how you set it up?)
Just curious… which way does yours go?

I personally do not go by every hour instead I use a breakfast time, Lunch Time, Dinner Time. I have it setup to tag the orders based on time of day.

[Sales:1, 1]
$1|[${REPORT TICKET DETAILS:([T.TotalAmount]).Sum:(TT.Service=$1)}]

[Percent Sales:1, 1]
$1|[=F({REPORT TICKET TOTAL:(TT.Service=$1)} / {REPORT TICKET TOTAL:(TT=Service)})*100]

So you tag the ticket based on ticket created time?
When I get to this would like to maybe try tagging on order level on hour basis as above as would be handy for their manager to better see peak times of the day and ensure sufficient staff on duty etc.

why order level? Its a ticket tag so you onle need to tag once .

As the aim would see when the busy times are, as sometime tickets - especially might be open customer bar tabs might be open all day or over lunch & dinner.
Would I be right to say that with ticket tag the whole ticket value would go to the time that the ticket was opened?
Say if someone came in at 12 and started a tab with drinks, wife came in at 4 - they both had food and stayed for few more drinks till say 6 or 8, their bill could easily be over £100. If im right to say the value would be tagged as ticket start time this would be £100+ at 12noon.
Does that make sense?

The exemple that i posted here is not from sambapos. I saw it on a friend pos and I’m trying to make this report on custom reports.
Sql or tags report it does not matter.
Can you please help me out?

There is a post with a few reports here, not had much practice with reports;

Ok that makes sense JTRTech. My method works but the issue with the report your looking for it would require a LOT of tags and doesnt seem realistic. It might be better to just build it with SQL. @emre has provided examples many times let me see if I can find one.

Please, is Joe :smile:
Its not important at this time, have more general work to do before looking too heavily at custom reports.
My samba development has had to go on back burner as have allot on at the minute. Was just a curiosity…

1 Like

@pizzaeilat4 do you want the report to look exactly like the one you showed sales per every hour? Or do you want it broken down to specific blocks of time like I did with Breakfast, Lunch, Dinner?

Thank you so much.
I like it to be Exactly the same if possible.
Also will it work on v4? Or only on v5?

You can use SQL in either version. I am pretty sure @gerlandog has put sample report showing Tickets Per Hour with sales.

I serched but could not find any

Was this the one? Is by gerlandog…

Thats it, you can customize that one to do what you want it shows the gist of how to build the sql.

For next version I’ve added Format Time (FT) function support to V5 reports so you can create something like that.

[ORDERS:1, 1, 1,1]
>Time|Order Count|Total|Percent
{REPORT ORDER DETAILS:FT([O.Time],'hh'),O.Id.Count,O.Total.Sum,O.Total.Percent}


This is great emre thanks.
I’m trying to help a friend, is there any way we can have this kind of report on v4?