# Proper Reports in Dolibarr

**URL:** <https://www.dolibarr.org/forum/t/proper-reports-in-dolibarr/15831>\
**Category:** Using my Dolibarr\
**Created:** [July 10, 2017, 4:29pm UTC](https://www.dolibarr.org/forum/t/proper-reports-in-dolibarr/15831 "2017-07-10T16:29:34Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![aljawaid](https://www.dolibarr.org/forum/user_avatar/www.dolibarr.org/aljawaid/32/388_2.png) [@aljawaid](https://www.dolibarr.org/forum/u/aljawaid)\
**Post date:** [July 29, 2017, 11:12am UTC](https://www.dolibarr.org/forum/t/proper-reports-in-dolibarr/15831/10 "2017-07-29T11:12:20Z")

</div>

Products with Country of Origin (Manufacturing Country) (highest first, ignoring blanks)

```auto
SELECT 
    llx_product.fk_country AS 'Country Code',
    llx_c_country.label AS 'Country',
    COUNT(*) AS 'Number of Products'
FROM
    llx_product
        INNER JOIN
    llx_c_country ON llx_product.fk_country = llx_c_country.rowid
GROUP BY fk_country
ORDER BY COUNT(*) DESC;
```

---

_[View the full topic](https://www.dolibarr.org/forum/t/proper-reports-in-dolibarr/15831)._
