Skip to Content
0
Former Member
Jan 05, 2006 at 02:11 PM

How to assign input values to WebService expecting an array?

12 Views

Hi All,

This is the structure of my web service.

Root Node (Request_MI_CreateAccInfOut_MI_CreateAccInfOut)

Inner Node (MT_AccInfoFlat)

Account Info (AccInfo)

Conditions( of cardinality 0..n)

I get a "Service call exception; nested exception is: com.sap.engine.services.webservices.jaxrpc.exceptions.XmlMarshalException: XML Serialization Error. Property [AccInfo] of class [com.test.model.proxies.types.DT_AccInfoFlat] must exist and can not be null. This is required by schema description." when I Execute the service.

Enclosed below is the code to assign values to the service in the controller. Where could I be wrong?

Request_MI_CreateAccInfOut_MI_CreateAccInfOut req = new Request_MI_CreateAccInfOut_MI_CreateAccInfOut();

wdContext.nodeRequest_MI_CreateAccInfOut_MI_CreateAccInfOut().bind(req);

ComplexType_DT_AccInfoFlat af = new ComplexType_DT_AccInfoFlat();

wdContext.nodeMT_AccInfoFlat().bind(af);

ComplexType_AccInfo ai = new ComplexType_AccInfo();

wdContext.nodeAccInfo().bind(ai);

ComplexType_Conditions con = new ComplexType_Conditions();

wdContext.nodeConditions().bind(con);

req.setMT_AccInfoFlat(af);

af.setAccInfo(ai);

af.addConditions(con);

ai.setAccountBegin("20050204");

ai.setAccountCrrcy("EUR");

ai.setAccountInternalNo("1E1F707EC00CC746ABCB38D93BE7339");

ai.setBankCode("90000001");

ai.setBankCountry("DE");

ai.setBP_No("0000502430");

ai.setLimitAmount("100");

ai.setLimitCategory("BCA010");

ai.setLimitCrrcy("EUR");

ai.setModificationType("M");

ai.setOrgId("50000619");

ai.setProduct("GIRO_SMB");

ai.setRadomNo("1");

con.setAmount("5.00");

con.setAmountCrry("EUR");

con.setConditionGrpType("310000");

con.setConditionType("115070");

con.setDateValidFrom("20050204");

con.setDateValidTo("99991231");

con.setDiffCateg1("006");

con.setDiffCateg2("021");

con.setDiffCateg3("002");

con.setDiffCateg4("001");

con.setFreeCount("");

con.setInterestCalcMethod("");

con.setItemNumber("1");

con.setRateInPercentage("");

con.setSettlementType("001");

Thanks in advance.

Best regards,

Divya