Jump to content
Sign in to follow this  

Need some SQL help merging All_prods

Recommended Posts


I installed the enable/ disable category contribution. It has you alter the Queries to the database, to reflect the change it made. It verifies that the cetegory status is '1'. This works great, but not perfect. I've installed some other contributions, and I need to incorporate this change into them.

I'm haveing a hard time especialy with the all_prods contribution. the query in it is

  $listing_sql = "select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, p.products_date_added, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on p.products_id = pd.products_id and pd.language_id = '" . $languages_id . "' left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where p.products_status = '1' order by p.products_price, pd.products_name";

I need to somehow add to this a line basically saying

where c.categories_status = '1' and...

, where as usual, C is TABLE_CATEGORIES.


I will also need help finding how to add this change to the categories dropdown list in the advanced search.




Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this