select count(*) as cnt from breed_store_multicategory a inner join breed_store_category b on a.cateno=b.cateno inner join breed_store_goods c on c.goodsno=a.goodsno where b.lft between AND and goods_view=0

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 and goods_view=0' at line 1