SELECT A.*,case A.cat_order when 0 then 999 else A.cat_order end as cat_orders,B.sCort, count(C.pro_id) as cat_pro_nums from bb_product_category A ,bb_product_category B left join bb_product C on C.cat_id = B.cat_id and C.pro_state=1 and C.pro_bbt_state <> 2 and C.pro_online_date<='2024-06-30 18:46:59' and C.pro_online_date!='0000-00-00 00:00:00' and C.user_id = '1047' and C.com_id = '1178' where A.user_id = '1047' and A.com_id = '1178' and substring(B.sCort,1,length(A.sCort))=A.sCort and A.cat_state = 1 and A.cat_parentid = 4550 and A.cat_bbt_state <> 2 group by A.cat_id order by A.cat_orderOut of resources when opening file '/data/tmp/#sql_369e_243.MAI' (Errcode: 24)