while select sum(TransFineWeight), sum(NetWtDeduction), ItemId, TagNo from TAGLINES
GROUP BY TAGLINES.TAGNO, TAGLINES.ITEMID
join BULKOLDTAGDESTROYDETAIL
where TAGLINES.TAGNO == BULKOLDTAGDESTROYDETAIL.TAGNO
join BULKOLDTAGDESTROY
where BULKOLDTAGDESTROYDETAIL.BULKTAGDESTROYNO == BULKOLDTAGDESTROY.BULKTAGDESTROYNO
join iNVENTJOURNALTRANS
where BULKOLDTAGDESTROY.JOURNALID == iNVENTJOURNALTRANS.JOURNALID
join iNVENTDIM
where iNVENTJOURNALTRANS.INVENTDIMID == iNVENTDIM.INVENTDIMID
join MELTINGTABLE
where iNVENTDIM.INVENTBATCHID == MELTINGTABLE.BATCHID
&& MELTINGTABLE.INPUTITEMID == TAGLINES.ITEMID
while select sum(TransFineWeight), sum(NetWtDeduction), ItemId, TagNo from tagLines
public void UpdateJob() { BULKOLDTAGDESTROY BULKOLDTAGDESTROY; BULKOLDTAGDESTROYDETAIL BULKOLDTAGDESTROYDETAIL; INVENTJOURNALTRANS iNVENTJOURNALTRANS; INVENTDIM iNVENTDIM; MELTINGTABLE MELTINGTABLE,meltingTableUpdate; TAGLINES TAGLINES; int updateCount = 0; real TransFineWeightSum; real NetWtDeductionSum; ttsbegin; while select sum( TAGLINES.TRANSFINEWEIGHT), //error ')' expected sum( TAGLINES.NetwtDeduction), TAGLINES.TAGNO, TAGLINES.ITEMID from TAGLINES join BULKOLDTAGDESTROYDETAIL on TAGLINES.TAGNO = BULKOLDTAGDESTROYDETAIL.TAGNO join BULKOLDTAGDESTROY on BULKOLDTAGDESTROYDETAIL.BULKTAGDESTROYNO = BULKOLDTAGDESTROY.BULKTAGDESTROYNO join INVENTJOURNALTRANS on BULKOLDTAGDESTROY.JOURNALID = INVENTJOURNALTRANS.JOURNALID join INVENTDIM on INVENTJOURNALTRANS.INVENTDIMID = INVENTDIM.INVENTDIMID join MELTINGTABLE on INVENTDIM.INVENTBATCHID = MELTINGTABLE.BATCHID && MELTINGTABLE.INPUTITEMID = TAGLINES.ITEMID
​​​​​​​ group by aCXTAGLINES.TAGNO,aCXTAGLINES.ITEMID { select forupdate meltingTableUpdate where meltingTableUpdate.BatchId == iNVENTDIM.INVENTBATCHID && MELTINGTABLE.INPUTITEMID == TAGLINES.ITEMID; if (meltingTableUpdate) { meltingTableUpdate.TRANSFINEWEIGHTNEW = TAGLINES.TRANSFINEWEIGHT; meltingTableUpdate.NetWtDeduction = TAGLINES.NetwtDeduction; meltingTableUpdate.update(); updateCount++; }
} ttscommit; info(strFmt("Updated %1 records in MELTINGTABLE.", updateCount)); }
ttsbegin;
while select sum( TAGLINES.TRANSFINEWEIGHT) as TransFineWeightSum, // in here i am getting error stating')' isn't declared
sum( TAGLINES.NetwtDeduction) as NetWtDeductionSum,
TAGLINES.TAGNO,
TAGLINES.ITEMID
from TAGLINES
join BULKOLDTAGDESTROYDETAIL where TAGLINES.TAGNO == BULKOLDTAGDESTROYDETAIL.TAGNO
join BULKOLDTAGDESTROY where BULKOLDTAGDESTROYDETAIL.BULKTAGDESTROYNO == BULKOLDTAGDESTROY.BULKTAGDESTROYNO
join iNVENTJOURNALTRANS where BULKOLDTAGDESTROY.JOURNALID == iNVENTJOURNALTRANS.JOURNALID
join iNVENTDIM where iNVENTJOURNALTRANS.INVENTDIMID == iNVENTDIM.INVENTDIMID
join MELTINGTABLE where iNVENTDIM.INVENTBATCHID == MELTINGTABLE.BATCHID
&& MELTINGTABLE.INPUTITEMID == TAGLINES.ITEMID
where TAGLINES.TRANSFINEWEIGHT != 0.00
&& TAGLINES.NetwtDeduction != 0.00
group by TAGLINES.TAGNO, TAGLINES.ITEMID
{
MELTINGTABLE.reread();
MELTINGTABLE.TRANSFINEWEIGHTNEW = TransFineWeightSum;
MELTINGTABLE.NetWtDeduction = NetWtDeductionSum;
MELTINGTABLE.update();
updateCount++;
}
ttscommit;
while select sum(
TransFineWeight), sum(NetWtDeduction), ItemId, TagNo from tagLines group by ItemId, TagNo where ... { }
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 290,435 Super User 2024 Season 2
Martin Dráb 228,317 Most Valuable Professional
nmaenpaa 101,148