Tag Wise Item Sale Report

Yer, what were you expecting?
That matches what you put
You need to include it in the main expression of you want it to be part of report.
You put on it’s own in front so that’s what’s rendered, list of tags for each order.

Please use kb.sambapos.com and go to reports section to learn how to use custom reports.

oh ok, but not very good in the technical, if some one can help pls let me know how this can be done.

The columns are in the report,
What you have done is said;

{Report tags}
{Report orders}

That’s two reports.

You need to include tags in the report you want them part of.
Ie
{Report orders:name,tag,total etc…

There is predictive field popup on the main expressions of which report orders is one of them, look through the suggestions in the popup.

thank you, got littel


with following templet

[Group Sales by Amount:1,2, 1, 1]

{REPORT ORDER DETAILS:M.Tag,O.ItemGroup,O.Total.Percent.desc,O.Total.Sum:(ODI=True)}
> |Total||{REPORT ORDER DETAILS:O.Total.Sum:(ODI=True)}


[Group Sales by Quantity:1,2, 1, 1]
{REPORT ORDER DETAILS:M.Tag,O.ItemGroup,O.Quantity.Percent.desc,O.Quantity.Sum:(ODI=True)}
>|Total||{REPORT ORDER DETAILS:O.Quantity.Sum:(ODI=True)}

[Sales:1, 2, 1,1]
@{REPORT ORDER DETAILS:O.MenuItemName,O.Total.Sum.desc:(ODI=True):{0}:,}
>{REPORT ORDER DETAILS:M.Tag,O.MenuItemName,O.Quantity.Sum.desc,O.Total.Sum.desc:(ODI=True) and O.MenuItemName="$1"}
{REPORT ORDER DETAILS:'     '+[O.PortionName],O.Quantity.Sum.desc,O.Total.Sum.desc:(ODI=True) and O.MenuItemName="$1":2}

We need Seprate list of food only and Bar Only can you help to get that.

Please start formatting your reports. Past it in then put ``` before and after it to format it in the forum so it’s readable.

you mean the templet you are saying

I mean when you paste a report in the forum. You see how it’s unreadable? Put the ``` before it. Paste it then put that after it at end. I will edit your post and do it for you this time.

Ok, Thank you we will do it next time, :slight_smile:

Hi,
any one who have solution to get the Report of Food Tag Separately and Bar Tag Separately,
thank you

You need to either manual split table and add a report constraint in the section with the odi= bit
Ie :(ODI=True) && M.Tag=Bar: , this may not be 100% as freehanding it.
Or use @ declaration to list tags and use similar to above with =$1 if it needs to be dynamic.
I use a similar split method with tags however my tags are transferred to order states on order adding due to other parts of my system. Think my reports use the state but will check later.
I have a total food/drink solution my receipts and wp report but again think I used my states rather than direct back to product tag.

Hey , thank you very much, this look very technical… i am not that technical, will ask some one who can understand your technical word see if i can sort out…
Thank you very much…:slight_smile:

Here is how I would do it on mine.
My wet/dry is defined by a named tag rather than the one you used.
image

(MT.NewBook GLA=2101)

So gussing yours might work with M.Tag=

So try

:(ODI=True) && (M.Tag=Bar):

Hey thank you for kind reply.

check with
{REPORT ORDER DETAILS:M.Tag}

but with

{REPORT ORDER DETAILS:M.Tag=Bar}
there is no report generated

Because your not listening to what im saying.

You want to report bar and drink seperatly. So you have to add a constraint to the report.
(ODI=True) is a constraint to only report items which are set to decrease inventory (so ignoring coid items etc - depending on your config)
So you need to add you tag to the constraint do the report only reports items with that tag…

This is reporting M.Tag for all orders, so gives a list of just the tag value for each order reported.

This is invalid as you put a constraint in place of where the reported fields should be.
‘M.Tag=Bar’ is not a valid column/field to report. Even if it was valid and expression validated all it might have given you is true, true, false, false etc in place of where you were reporting tags, as to whether that order details line matched the expression, but its invalid anyway so forget it. M.Tag is a column

Reports are formatted in sections seperated by colons ( : )

So take this from your earlier report;

{REPORT ORDER DETAILS: = the report type, what is to be reported

M.Tag,O.ItemGroup,O.Total.Percent.desc,O.Total.Sum = your report fields, what data to be reported

:(ODI=True) = your constraints/filters

So you need to do something like this;

{REPORT ORDER DETAILS:O.ItemGroup,O.Total.Percent.desc,O.Total.Sum:(ODI=True)&&(M.Tag=Bar)}

Note that I dont use the plain tag column and specify all my product tags with own columns as shown in my screenshots. The above works with my (MT.NewBook GLA=2101) which is equivilent of your Bar in default tag column.

If you still dont understand then you need to go back to basics and read up on reports as dont know how to explain it simpler than that.

Yes i tried like same what you have send, it is not working.
{REPORT ORDER DETAILS:O.ItemGroup,O.Total.Percent.desc,O.Total.Sum:(ODI=True)&&(M.Tag=Bar)}

Ok, so tested and looks like you cant use the Tag column for constraint.
Simple answer is create a popper menu item/product tag column for this ‘setting’ - call it whatever, ‘Department’

That will give you a 'Department column here;

Move your Food/Bar from Tag to ‘Department’

Then use

{REPORT ORDER DETAILS:O.ItemGroup,O.Total.Percent.desc,O.Total.Sum:(ODI=True)&&(MT.Department=Bar)}

1 Like

Hey, it worked

thank you

1 Like

If you wanted to learn and get creative you could try using an @ expression and $1.

@Food,Bar
[$1 Sales by Amount:2, 1, 1]
{REPORT ORDER DETAILS:O.ItemGroup,O.Total.Percent.desc,O.Total.Sum:(ODI=True)&&(MT.Department=$1)}
> |Total||{REPORT ORDER DETAILS:O.Total.Sum:(ODI=True)&&(MT.Department=$1)}

In theory you would use a report expression for the @ too to make it truly dynamic.
The @ declairs a list which is the ‘mail merged’ into the report, repeating the report for each value in the list and the value is represented by the $1.

Not tested that as on phone but should give you the idea.

Thank you.
will try that…