select count(distinct p.products_id) as total  from typ_to_products as t2p, products_description pd,  stany_products sp, stany st, products p left join manufacturers m on p.manufacturers_id = m.manufacturers_id left join specials s on p.products_id = s.products_id, products_to_categories_new p2c where p.products_id = st.products_id and p.products_id = sp.products_id and p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '19'  and sp.dostepny = 1  and p2c.categories_id = '100482' and t2p.products_id = p.products_id and t2p.typ_id = '9974'