SELECT * FROM
(select a.id,a.name as an,c.`name` as cn,a.GoodsCategoryID,a.GoodsProValue,a.GoodsBrandID,a.brand_name, a.category_more1,b.brand_more2
from gok_zolit_goods a join hg_original_type b on a.id=b.fromid
LEFT JOIN gok_zolit_brand AS c on a.GoodsBrandID = c.id) as tt WHERE LOCATE(tt.cn,tt.an) <=0;