static void
OGSReleaseInevnttableVariants(Args _args)
{
EcoResProduct ecoResProduct;
InventDimCombination inventDimCombination;
InventTable InventTable;
int
success, errors;
changeCompany('alma')
{
while
select ecoResProduct
join InventTable
notExists
join inventDimCombination
where
(ecoResProduct.DisplayProductNumber == inventDimCombination.ItemId) &&
(InventTable.ItemID == ecoResProduct.DisplayProductNumber)
{
try
{
EcoResProductReleaseManagerBase::releaseProduct(ecoResProduct.RecId,
CompanyInfo::findDataArea('alma').RecId);
success++;
}
catch
{
errors++;
continue;
}
}
}
info(strFmt("Complete: %1 records success, %2
errors/skipped",success,errors));
}
No comments:
Post a Comment