Unknown column 'type' in 'where clause'
select count(*) as num from ***_ecms_article where classid=3 and type='2'