https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21507 Arthur Suzuki <arthur.suzuki@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |arthur.suzuki@biblibre.com --- Comment #2 from Arthur Suzuki <arthur.suzuki@biblibre.com> --- Here is a SQL query which helps detecting incoherences in the account lines. SELECT invoicenumber, link.ordernumber, items.itemnumber, unitprice, unitprice_tax_excluded, unitprice_tax_included, items.price, ecost, unitprice_tax_excluded/ecost as ratio FROM aqorders LEFT JOIN aqinvoices ON aqinvoices.invoiceid = aqorders.invoiceid LEFT JOIN aqorders_items as link ON link.ordernumber=aqorders.ordernumber LEFT JOIN items ON link.itemnumber=items.itemnumber WHERE unitprice/ecost > 5 OR unitprice_tax_excluded/ecost > 5 OR items.price/ecost > 5 ORDER BY ratio DESC; -- You are receiving this mail because: You are watching all bug changes.