jonsa79 Posted October 22, 2005 Posted October 22, 2005 I get this error when I enter advanced_search.php: 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and cd.language_id = '1' order by sort_order, cd.categories_name' at line 1 select c.categories_id, cd.categories_name from categories c, categories_description cd where parent_id = '0' and c.categories_id = cd.categories_id and and cd.language_id = '1' order by sort_order, cd.categories_name [TEP STOP] Any OsC-pro know what I have done wrong? Thanks, jonsa
241 Posted October 22, 2005 Posted October 22, 2005 you have and and instead of a singular and No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix raising oscommerce from the ashes.
jonsa79 Posted October 22, 2005 Author Posted October 22, 2005 Thanks Steve! Where do I change this? I've looked in both advanced_search.php and advanced_search_results.php, and couldn't find it. Is it in the database? Thanks.
jonsa79 Posted October 23, 2005 Author Posted October 23, 2005 Can't find where to change this. Does anyone know how to fix this? :(
241 Posted October 24, 2005 Posted October 24, 2005 You must have installed a contribution which has altered your catalog/includes/functions/general.php function tep_get_categories at the categories query, below is an original $categories_query = tep_db_query("select c.categories_id, cd.categories_name from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where parent_id = '" . (int)$parent_id . "' and c.categories_id = cd.categories_id and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); Yours will have this $categories_query = tep_db_query("select c.categories_id, cd.categories_name from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where parent_id = '" . (int)$parent_id . "' and c.categories_id = cd.categories_id and and cd.language_id = '" . (int)$languages_id . "' order by sort_order, cd.categories_name"); No longer giving free advice. Please place deposit in meter slot provided. Individual: [=] SME: [==] Corporation: [===] If deposit does not fit one of the slots provided then you are asking too much! Is your Osc dated try Phoenix raising oscommerce from the ashes.
jonsa79 Posted October 25, 2005 Author Posted October 25, 2005 Thank you Steve! That fixed the problem!! :D Regards, Daniel
Recommended Posts
Archived
This topic is now archived and is closed to further replies.