Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Error while deploying loop in scripting


We are working on SAP e sourcing 5.1

I am trying to access all the master agreement with Display_Name beginning with "A" and trying to change expiration date based on an integer value extension field "RENEWAL_DUR_YEAR". I have written the following script for the same


import com.frictionless.api.contracts.ContractIBeanIfc;

import java.text.*;

import java.util.*;

import java.lang.*;

import com.frictionless.api.ibean.IBeanHomeLocatorIfc;

import com.frictionless.api.ibean.IBeanHomeIfc;

import com.frictionless.api.contracts.*;

import java.text.SimpleDateFormat;

import com.frictionless.api.ibean.OrderedSubordinateCollectionIfc;

logMsg = Logger.createLogMessage(session);

contractHome = IBeanHomeLocator.lookup(session,com.frictionless.api.contracts.ContractIBeanHomeIfc.sHOME_NAME);

contractList = contractHome.findWhere("DISPLAY_NAME LIKE 'A%' '');

for(Iterator iterator1 = contractList.iterator(); iterator1.hasNext();)


ContractIBeanIfc masterAgreement = (ContractIBeanIfc);

ExpirationDate = masterAgreement.getExpirationDate().getDate();

Calendar cal2=Calendar.getInstance();


durationYear = masterAgreement.getExtensionField("RENEWAL_DUR_YEAR").get();





I am getting the following error:

Error executing script: Sourced file: inline evaluation of: ``import com.frictionless.api.contracts.ContractIBeanIfc; import java.text.*; imp . . . '' : Method Invocation masterAgreement.setExpirationDate.

setExpirationDate is working fine otherwise. Is there something I am missing? please suggest


Mudit Saini

Edited by: Mudit_UCB on May 18, 2011 10:33 AM

Edited by: Mudit_UCB on May 18, 2011 10:49 AM

Former Member
Not what you were looking for? View more on this topic or Ask a question