下图是在BI里自动生成的明细表,请问在Report里如何实现,在Report做明细是因为在明细表下有一块填报和一块计算表 附SQL语句! SELECT b.FDetailID as '序号', a.FDate as '日期', c.FName as '产品名称', c.FNumber as '物料编码', b.FQty as '数量', e.FName as '仓库', (case when left(c.FNumber,4)='2.28' then 'BOSA' when left(c.FNumber,4)='2.01' then '外延片' when left(c.FNumber,4)='2.07' then 'CHIP' when left(c.FNumber,4)='2.17' then 'TO46' when left(c.FNumber,4)='2.16' and left(e.FName,2)='石狮' then 'TO5' when left(c.FNumber,4)='2.16' and left(e.FName,2)!='石狮' then 'TO' when left(c.FNumber,4)='2.26' then 'TOSA' when left(c.FNumber,4)='2.27' then 'ROSA' when left(c.FNumber,4)='2.51' OR left(c.FNumber,4)='2.52' OR left(c.FNumber,4)='2.53' OR left(c.FNumber,4)='2.54' OR left(c.FNumber,4)='2.55' OR left(c.FNumber,4)='2.56' OR left(c.FNumber,4)='2.57' OR left(c.FNumber,4)='2.58' then '模块' when left(c.FNumber,4)='2.59' OR left(c.FNumber,4)='2.60' then 'ITLA模块' else '其他类型' end )'产品类别' from ICStockBill a ---出入库单据 join ICStockBillEntry b on a.FInterID=b.FInterID ---出入库明细 join t_ICItem c on b.FItemID=c.FItemID ---物料 join ICTransType d on a.FTranType=d.FID ---单据类型 join t_Stock e on e.FItemID =b.FDCStockID ---仓库 where d.fid='2' and (a.FHeadSelfA0235!='990204' or a.FHeadSelfA0235 is null) ---过滤返工入库 order by a.FDate desc |