:
SELECT 10000 * (6/106)
, : 566.0377
, , cents, :
SELECT ROUND(10000*(6/106),2)
, () DECIMAL. ,
DECIMAL(10,2)
// .
. ,
SELECT 24*(6/106)*CAST(1.20 AS DECIMAL(10,2))
will give 6% of the net VAT for two dozen pieces, the cost of which is 1.20.
To do this without unnecessary queries, you may need to ALTER some definitions of your columns.
I tried this on MariaDB 10, MySQL 5.1, 5.5 and 5.6. Seems good.
source
share