Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Error: 1066 - Not unique table/alias:


Wizard

Recommended Posts

Hi,

 

I wanted to create a more advanced search, by adding a second category similar to the manufacturers. I changed and duplicated (accordingly) all the files that had the manufacturers code and created a new category called color. Everything seems to be working fine, except for the advanced search.

 

When running the advanced search I get the following message on the screen:

 

1066 - Not unique table/alias: 'm'

 

select count(*) as total from products p left join manufacturers m using(manufacturers_id), color m using(color_id), products_description pd left join specials s on p.products_id = s.products_id, categories c, products_to_categories p2c left join tax_rates tr on p.products_tax_class_id = tr.tax_class_id left join 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 = '223') and (gz.zone_id is null or gz.zone_id = '0' or gz.zone_id = '12') where p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '1' and p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and (IF(s.status, s.specials_new_products_price, p.products_price) * if(gz.geo_zone_id is null, 1, 1 + (tr.tax_rate / 100) ) <= 1000000)

 

[TEP STOP]

 

Any clues what I should do to fix it?

Who would have thought that so much can be created from 0`s and 1`s...

Link to comment
Share on other sites

I found out that my problem is in the advanced_search_result.php file. When I deleted all the code that involves the manufacturers, the advanced search worked fine with the new color category.

 

So I guess my question now is how do I add another search category into the advanced_search_result.php file?? :?

 

Ideas anyone?

Who would have thought that so much can be created from 0`s and 1`s...

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...