,,,, Posted August 6, 2008 Share Posted August 6, 2008 (edited) Howdy, i spent the last 2 days with installing contribution # 2202 (Products Extra Fields) and i'm fed up! I read numerous threads about manifold problems with this contribution; that doesn't surprise me at all, because reading the installing instructions with it's mixture of "add before, add after, add directly before, add directly after, replace, ..." is only possible directly after you have a wash. Secondary i can't find a section mentioned in the installing instruction included in version 2_0j from user 'wdepot' on 13 Jun 2008: $from_str = "from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m using(manufacturers_id), " . TABLE_PRODUCTS_DESCRIPTION . " pd left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id, " . TABLE_CATEGORIES . " c, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c"; This section should be found in advanced_search_result.php, but i only find this: $from_str = "from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m using(manufacturers_id) left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id"; And of course after installing Product Extra Fields my advanced search crashes with error 1066 (Not unique table/alias: 'pd'). Somebody wrote that removing the following line will help to fix this error: $from_str .= ", " . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_CATEGORIES . " c, " . TABLE_PRODUCTS_TO_CATEGORIES . " p2c"; He is right, now i get not error 1066, but error 1054 (Unknown column 'p.products_id' in 'on clause') and i don't know why?!? I'm using PHP5/MySQL5. Perhaps i am too stupid for this contribution, but i'm not alone! Please tell me WHAT version YOU installed successfully on PHP5/MySQL5/osC2.2rc2a and how you worked around the difference between the installing instruction 2_0j and the osCommerce version 2.2rc2a in advanced_search_result.php...thanks a lot! ,,,, Edited August 6, 2008 by ,,,, Quote Link to comment Share on other sites More sharing options...
♥geoffreywalton Posted August 6, 2008 Share Posted August 6, 2008 This is my line 216 in search results if ( (DISPLAY_PRICE_WITH_TAX == 'true') && (tep_not_null($pfrom) || tep_not_null($pto)) ) { $select_str .= ", SUM(tr.tax_rate) as tax_rate "; } // START: Extra Fields Contribution - SM 10/03/08 - this doesn't work // $from_str = "from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m using(manufacturers_id) left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id"; //$from_str = "from (" . TABLE_PRODUCTS . " p left join " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " p2pef on p.products_id=p2pef.products_id) left join " . TABLE_MANUFACTURERS . " m using(manufacturers_id) left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id"; $from_str = "from (" . TABLE_PRODUCTS . " p left join " . TABLE_PRODUCTS_TO_PRODUCTS_EXTRA_FIELDS . " p2pef on p.products_id=p2pef.products_id) left join " . TABLE_MANUFACTURERS . " m ON m.manufacturers_id = p.manufacturers_id left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id"; // END: Extra Fields Contribution if ( (DISPLAY_PRICE_WITH_TAX == 'true') && (tep_not_null($pfrom) || tep_not_null($pto)) ) { if (!tep_session_is_registered('customer_country_id')) { $customer_country_id = STORE_COUNTRY; $customer_zone_id = STORE_ZONE; } $from_str .= " left join " . TABLE_TAX_RATES . " tr on p.products_tax_class_id = tr.tax_class_id left join " . TABLE_ZONES_TO_GEO_ZONES . " gz on tr.tax_zone_id = gz.geo_zone_id and (gz.zone_country_id is null or gz.zone_country_id = '0' or gz.zone_country_id = '" . (int)$customer_country_id . "') and (gz.zone_id is null or gz.zone_id = '0' or gz.zone_id = '" . (int)$customer_zone_id . "')"; } Might help, might be totally misleading. But it works for me on mysql5 Quote Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile Virus Threat Scanner My Contributions Basic install answers. Click here for Contributions / Add Ons. UK your site. Site Move. Basic design info. For links mentioned in old answers that are no longer here follow this link Useful Threads. If this post was useful, click the Like This button over there ======>>>>>. Link to comment Share on other sites More sharing options...
,,,, Posted August 6, 2008 Author Share Posted August 6, 2008 WOW! You made my day...thank you very much, with your sql-query it works fine. :D Quote Link to comment Share on other sites More sharing options...
♥geoffreywalton Posted August 7, 2008 Share Posted August 7, 2008 Not mine, just searched around a bit. You could always update the contribution to help those that follow you Quote Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile Virus Threat Scanner My Contributions Basic install answers. Click here for Contributions / Add Ons. UK your site. Site Move. Basic design info. For links mentioned in old answers that are no longer here follow this link Useful Threads. If this post was useful, click the Like This button over there ======>>>>>. Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.