Interview Questions

Wednesday, March 26, 2014

Find Purchase Order in which items have specific Dimension Group ID

static void X(Args _args)
{
    PurchTable   _purchTable,tableloc;
    PurchLine    _purchLine;
    InventDim    _inventDim;
    InventTable  _inventTable;
    ;
    While select  tableloc // where tableloc.PurchId =='Enter Purch ID'
    while select  _purchLine  where _purchLine.PurchId == tableloc.PurchId
        {
                 if(InventTable::find(_purchLine.ItemId).DimGroupId == 'SWL')
                       {
                                  info (strfmt("%1, %2", _purchLine.PurchId,_purchLine.ItemId));
                       }
        }
}

No comments:

Post a Comment