Okay, I've run into unsual cituation with Exp:resso Store and hope that the community will be able to help.

The site I'm working on is selling prints and the purchase's price is built depending on print dimentions. So in the backend, the item's price is set per square cm, then on front-end I have simple Javascript calculator which turns the width and height that user inputs into square area. Which, multiplied to the item's cost per cm, is the order subtotal.

Such setup means that the price for square cm is quite low (and minumum order is 0.5 square meter)

I have "Currency Decimal Places" setting set to "8".

But I found out I can't really enter amount like "0.000095"as the item price - it's getting rounded to "0.00010000" when the entry is saved.

Can anyone suggest what do do here to prevent rounding?

Or maybe some alternative solution which would allow me to charge for the print based on its square area?

Running Store 2.3.1 on EE 2.9.0

Thanks a lot!

1 Answer 1


Appears that the restriction on number of decimals is set directly in database.

I've got it fixed by running these queries:

ALTER TABLE `exp_store_products` CHANGE `price` `price` DECIMAL( 19, 8 ) NULL DEFAULT NULL ;

ALTER TABLE `exp_store_order_items` CHANGE `price` `price` DECIMAL( 19, 8 ) NOT NULL DEFAULT '0.0000';

ALTER TABLE `exp_store_order_items` CHANGE `regular_price` `regular_price` DECIMAL( 19, 8 ) NOT NULL DEFAULT '0.0000';

  • Good catch; seeing this reminded me to not forget database issues (column attributes) with EE core as well as third-party add ons when running into strange/unexplained value modifications.
    – jrothafer
    Jan 23, 2016 at 6:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.