I have used the GROUP_CONCAT construct to support returning multiple attributes for a single product. It saves a lot of queries on getting those details; by making the listing query more complex... No idea by the way how it performs.
Paul
- osCommerce Support Forum
- → Viewing Profile: pbor1234
Latest News: (loading..)
Community Stats
- Group Community Member
- Active Posts 86 (0.06 per day)
- Most Active In General Add-Ons Support (35 posts)
- Profile Views 10,764
- Age 36 years old
- Birthday February 1, 1976
-
Real Name
Paul
-
Gender
Male
-
Location
The Netherlands
0
Neutral
Friends
pbor1234 hasn't added any friends yet.
Latest Visitors
Posts I've Made
In Topic: Speed Up Database Query with MySQL 5+ (and more with MySQLi Extension)
02 October 2011, 19:37
In Topic: Dangling Carrot (Free Gift/Discount Contrib)
30 September 2011, 20:31
I was looking at the sql modifications and have doubts. It seems to be possible to filter on gifts without the additional column to products:
select count(distinct p.products_id) as total
from
products p
left join (specials s) on (p.products_id = s.products_id)
left join (products_description pd) on (p.products_id = pd.products_id and pd.language_id = '4')
<...>
left join (`free_gifts` f) on (p.products_id = f.products_id)
where
p.products_status = '1' and f.products_id IS NULL
Anyone thoughts on this?
Paul
select count(distinct p.products_id) as total
from
products p
left join (specials s) on (p.products_id = s.products_id)
left join (products_description pd) on (p.products_id = pd.products_id and pd.language_id = '4')
<...>
left join (`free_gifts` f) on (p.products_id = f.products_id)
where
p.products_status = '1' and f.products_id IS NULL
Anyone thoughts on this?
Paul
In Topic: [Contribution] Discount Coupon Codes
02 March 2011, 21:20
wvlenthe, on 01 March 2011, 08:16, said:
I have tried to reproduce this.
<...>
<...>
Hoi Wiljo,
Might be that i was seeing the tax on giftwrap + tax on shipping (iso tax on products).
It's wrong anyway,,,,
I guess i need to refactor simply the workings on discount_coupons the class + integration into the order.
Thing is that each ot-contribution is hacked differently into the codebase
BTW: Have you tried to use the order_editor (contribution) icw added ot's? Try to update the order-total items and see what happens....
Paul
In Topic: [Contribution] Discount Coupon Codes
28 February 2011, 21:52
Found another issue; display prices with tax = 'true', then create an order of 5$ + shipping of 3$ (for example), include discount coupon fixed 10$, in the total/confirmation page you will notice that the total price isn't 0 but equal to the tax of products + shipping.
It's the ot_'s that add the tax to the $info['total'].
I'm working on a hack to correct the 'total' from the ot_discount_coupon::process(); moving finalize_discount here seems to do the trick but i have no clue what impact of such change may be; since the modules are also used by admin...!?
Paul
It's the ot_'s that add the tax to the $info['total'].
I'm working on a hack to correct the 'total' from the ot_discount_coupon::process(); moving finalize_discount here seems to do the trick but i have no clue what impact of such change may be; since the modules are also used by admin...!?
Paul
In Topic: [Contribution] Discount Coupon Codes
24 February 2011, 20:13
wvlenthe, on 23 February 2011, 20:13, said:
You are totally correct when you say customers want prices including tax. I'm merely saying calculation needs to be on the base price to be able to allow for multiple tax rates. DCC works for me displaying discounts including taxes on checkout (well, except for the (free) shipping discount), the customer doesn't get bothered with tax. The only thing I have to remember is to define the discount without tax (I have added an extra text to the discount input page as a reminder).
Wiljo,
If i want give EUR 5 discount (incl tax), i may need to enter 4,20 (excl 19% tax) or 4,72; or anything in between since customer may order 19% tax'ed items and/or 6% items. So it doesn't work on the base price...?
Regarding the $tax_address; if i die/print_r, i see its simply not defined, even when i declare it global, it's not defined. I do have it in classes/order.php but there its a local as well. See also php.net
Paul
- osCommerce Support Forum
- → Viewing Profile: pbor1234
- Forum Rules






Find content