|
|
|||
|
|||
|
我有两个数据集:一个是:inventory 两一个是:stadium
我将它们通过 joint data set 进行连接用得是full outre join 这种联合数据集。 inventory中的 open(): var inDepotList=inven.getIODepotCount(inventoryId,startDate,finishDate,depotId); iterator=inDepotList.iterator(); fetch()方法: if(!iterator.hasNext()){ return false; } else{ var list =iterator.next(); row["date"]=list[0].getInputDate(); row["vouchType"]=list[0].getVouchType().getName(); row["ioDepotId"]=list[0].getIoDepotId(); if(list[0].getVouchType().getType()==0){ row["InDepot"]=list[1].getQuantity(); }else{ row["OutDepot"]=list[1].getQuantity(); } row["remain"]=stadium+row["InDepot"]-row["OutDepot"]; stadium=row["remain"]; return true; } 两一个数据集stadium中: open(): var InvenDepotList=inven.getInventoryDepot(inventoryId,depotId); iterator1=InvenDepotList.iterator(); currentCount=inven.getStadium(inventoryId,startDate,depotId); fetch()方法: if(!iterator1.hasNext()){ return false; } else{ var list =iterator1.next(); row["autoId"]=inventoryId; row["depotName"]=list[0].getDepot().getName(); row["period"]=startDate+"至"+finishDate; row["inventoryName"]=list[1].getInventory().getStandardName(); row["stadium"]=currentCount; return true; } 当运行报表的时候inventory中实际上只有七条数据,可在运行的时候每条记录都会遍历很多行。如果将数据集stadium中的方法注释掉,运行报表的结果就是正确的只显示七条数据。 请问这种问题如何解决啊?这两个数据集中的close方法,我也写了啊.可就是不正确,请指点一下!!!谢谢了。 此帖于 2008-9-1 09:19 AM 被 hanzhongcheng 编辑. |
![]() |
| 主题工具 | 搜索本主题 |
| 显示模式 | |
|
|