chipset Posted June 15, 2014 Share Posted June 15, 2014 Hello, I add a SQL query: SELECT p.on_sale AS 'On Sale', m.name AS 'Manufacturer', pl.name AS 'Name', cl.name AS 'Categories', ROUND (p.price,0) AS 'Price' but I don't know how to export the real price. If I have product AAA with price $100 and special price $90, In the above example I see only $100. How to grab $90 (the real price)? Thanks Link to comment Share on other sites More sharing options...
vekia Posted June 15, 2014 Share Posted June 15, 2014 wtihout php coding it will be hard to get specifi price, it's because in special price table there is no price, just information about what kind of discount you defined. so to get final price, you have to do some math on variables from database Link to comment Share on other sites More sharing options...
chipset Posted June 15, 2014 Author Share Posted June 15, 2014 Thank You vekia. If I use spc.reduction, can do SQL query smothing like this: Real price = p.price - spc.reduction only if reduction_type is amount? Link to comment Share on other sites More sharing options...
chipset Posted June 15, 2014 Author Share Posted June 15, 2014 A temporary decision: SELECT ROUND (p.price,0) - ROUND(spc.reduction,0) AS 'Price' Link to comment Share on other sites More sharing options...
Recommended Posts