[Skip to main content](#vessel-content)

#   Report showing incorrect amount

##

- **[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")**
- [![a2zcs's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar33209.jpg)](/forum/user/33209-a2zcs "View a2zcs's Profile") Topic Author
- [ Offline](/forum/user/33209-a2zcs)

Less More

- Posts: 298
- Thank you received: 7
-
-

1 year 6 months ago [\#366869](#366869) by [a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")  *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366869 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")* was created by *[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")*

-- url of the page with the problem -- : eop-inc.com
-- HikaShop version -- : 5.1.6
-- Joomla version -- : 3.10.12
-- PHP version -- : 8.2.28
-- Browser(s) name and version -- : chrome
-- Error-message(debug-mod must be tuned on) -- : n/a

I've taken the "Weekly Performance" report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?

My report settings are:
Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31
Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result)
Options: Limit:100

All other settings are still at defualt

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86323
- Thank you received: 14283
-
-

1 year 6 months ago [\#366871](#366871) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366871 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

Hi,

You're not providing the full picture. If you really used the "weekly performance" report and changed its display type to "listing" without changing its "type" from "sales" to something else, the report will display a listing of your orders in that period of time.
There will be no sums of sales, and no category information displayed.
Did you change the type to "categories" ?
Could you please provide a screenshot of the settings of your report ?
Could you activate the "debug" setting of the Joomla configuration, and on the page of the report settings, look at the debug at the bottom and provide the MySQL queries there ? At least the one loading the data of the report.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")**
- [![a2zcs's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar33209.jpg)](/forum/user/33209-a2zcs "View a2zcs's Profile") Topic Author
- [ Offline](/forum/user/33209-a2zcs)

Less More

- Posts: 298
- Thank you received: 7
-
-

1 year 6 months ago [\#366875](#366875) by [a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")  Replied by *[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366875 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

Sorry yes, Categories
[ snipboard.io/sJU20j.jpg](https://snipboard.io/sJU20j.jpg)

There are 55 queries being shown in the debug, not sure which one you need.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86323
- Thank you received: 14283
-
-

1 year 6 months ago [\#366876](#366876) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366876 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

Hi,

Since the report is calculating sales, search for the MySQL query on the hikashop_order table. There should be only one on this page so if you search for "hikashop_order" you should directly find it.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")**
- [![a2zcs's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar33209.jpg)](/forum/user/33209-a2zcs "View a2zcs's Profile") Topic Author
- [ Offline](/forum/user/33209-a2zcs)

Less More

- Posts: 298
- Thank you received: 7
-
-

1 year 6 months ago [\#366878](#366878) by [a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")  Replied by *[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366878 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

Is this the one you are looking for?

\#32
SELECT *, SUM(order_full_price) as Total
FROM josdh_hikashop_order as a
LEFT JOIN josdh_hikashop_order_product as prod
ON a.order_id=prod.order_id
LEFT JOIN josdh_hikashop_product AS p
ON p.product_id=prod.product_id
LEFT JOIN josdh_hikashop_product_category as cat
ON cat.product_id=p.product_id OR cat.product_id=p.product_parent_id
LEFT JOIN josdh_hikashop_category as c
ON cat.category_id=c.category_id
WHERE a.order_type='sale'
AND a.order_status IN ('confirmed')
AND a.order_created &gt; 1735707600
AND a.order_created &lt; 1767157200
GROUP BY c.category_id
ORDER BY Total DESC
LIMIT 100

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86323
- Thank you received: 14283
-
-

1 year 6 months ago [\#366890](#366890) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366890 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

Hi,

Great. That's exactly what I needed.
I understand the problem. The issue is that in this specific case, the system takes into account the total amount of the order, even if only one product from the category is in the order. This can result is greatly over inflated numbers, especially on websites where users normally purchase products from different categories at the same time.
On our website for example, that's usually not the case. Users usually purchase only one extension at a time and so I didn't see any problem on my side.
I've made a patch for this. Download the install package of HikaShop on our website and install it on yours and you'll get the patch. It should then display proper numbers.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

- **[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")**
- [![a2zcs's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar33209.jpg)](/forum/user/33209-a2zcs "View a2zcs's Profile") Topic Author
- [ Offline](/forum/user/33209-a2zcs)

Less More

- Posts: 298
- Thank you received: 7
-
-

1 year 6 months ago [\#366894](#366894) by [a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")  Replied by *[a2zcs](/forum/user/33209-a2zcs "View a2zcs's Profile")* on topic *[Report showing incorrect amount](/forum/36-reports-statistics/909365-report-showing-incorrect-amount#366894 "-- url of the page with the problem -- : eop-inc.com -- HikaShop version -- : 5.1.6 -- Joomla version -- : 3.10.12 -- PHP version -- : 8.2.28 -- Browser(s) name and version -- : chrome -- Error-message(debug-mod must be tuned on) -- : n/a  I've taken the &quot;Weekly Performance&quot; report and turned it into an annual report. It is showing one category as having over $30,000 worth of sales when it has only had about $1,200. Other categories appear to be correct. Where could this innacuracy possibly be coming from?  My report settings are: Display: Type: Listing, Date Type: Created, Period 2025-01-01 to 2025-12-31 Filters: Order Status: Confirmed, Including Sub Categories Yes (No shows same result) Options: Limit:100  All other settings are still at defualt")*

I'll run it by the site owner for confirmation, but that looks so much better, thank you!

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM2LXJlcG9ydHMtc3RhdGlzdGljcy85MDkzNjUtcmVwb3J0LXNob3dpbmctaW5jb3JyZWN0LWFtb3VudD90bXBsPW1hcmtkb3du) or [Create an account](/register) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.078 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
