select
WorksheetID,worker,WorkDate,merchantName ,merchantNo ,manager
, case when insCount>0 then '新装' else '' end InsStr
,case when repCount>0 then '换装' else '' end RepStr
,case when UnInsCount>0 then '撤机' else '' end UnInsStr
,case when FaultCount>0 then '故障处理' else '' end FaultStr
,case when VisitCount>0 then '巡检' else '' end VisitStr
,case when SendConsumableCount>0 then '耗材配送' else '' end SendConsumableStr
,case when SoftUpdateCount>0 then '程序升级' else '' end SoftUpdateStr
,case when takeSheetCount>0 then '取送单据' else '' end takeSheetStr
from MaintainInfo_ReadyForData;