sales_id = 12
product_rate =
2090.00 making_charge = 83.60
handling_charge = 0.00
they are all decimal (10.2) types. My request
SELECT SUM( making_charge + product_rate + handling_charge ) AS tax_tourn
FROM `sales_details`
WHERE `sales_id` =12
As a result, I get
tax_tourn = 10784.40
which is not correct
2090.00 + 83.60 + 0.00 = 2173.60
why does mysql show the wrong answer?
Details Recently Added
I have two sales tables and sales_details. sales_id is the primary key for sales, and sales_details_id is the primary key for sales_details.sales_id is the foreign key in sales_details.In sales_details with the same sales_id, there may be multiple rows.(sales_id= 12) .