0 Replies Latest reply on Aug 5, 2009 1:22 PM by 694620

    Unable to add a Group  to other Group using Content DB API's.


      I am new to Content DB. I am creating the groups in Content DB using its API's. I am able to add the Users to a Group while Creating the Group itself. I am not able to add the group to the Member list while creating the Group. Can anyone provide me some sample code about how to add a group as a member to other group using Content DB API's.

      The code i have developed

      long[] managersList = new long[] { managerUser1.getId() , managerUser2.getId() };
      long[] membersList = new long[] {  memberUser1.getId() ,memberUser2.getId(), subGroups[0].getId()};

      AttributeRequest[] requestedAttributes = AttributeRequests.GROUP_ATTRIBUTES;
      Item group = null;

      group = groupM.createGroup(
      new NamedValue[]
      // name of new group - must be unique within the domain
      Attributes.NAME, "SC_12268"),
      // description
      ClientUtils.newNamedValue(Attributes.DESCRIPTION, "Sample Group"),
      // set of users whom will be able to manage this group

      ClientUtils.newNamedValue(Attributes.MANAGER_LIST, managersList),

      ClientUtils.newNamedValue(Attributes.MEMBER_LIST, membersList),

      Attributes.IS_EXTERNALLY_MANAGED, Boolean.TRUE),

      // group membership will be viewable by everyone in the domain
      }, requestedAttributes);

      I am getting this following user when adding a group as a member to other group

      Error : faultDetail:
           {http://xmlns.oracle.com/content/ws}fault:<detailedErrorCode xsi:type="xsd:string">ORACLE.FDK.InvalidAttribute</detailedErrorCode><errorCode xsi:type="xsd:string">ORACLE.FDK.ParameterError</errorCode><exceptionEntries xsi:type="ns1:ArrayOfFdkExceptionEntry" xsi:nil="true"/><info soapenc:arrayType="ns1:NamedValue[1]" xsi:type="soapenc:Array" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"><info xsi:type="ns1:NamedValue"><name xsi:type="xsd:string">GROUP_MEMBER_LIST</name><value soapenc:arrayType="xsd:long[1]" xsi:type="soapenc:Array"><value xsi:type="xsd:long">14176601</value></value></info></info><serverStackTraceId xsi:type="xsd:string">2502-1249472707488</serverStackTraceId>

      Please help me in solving this issue. This is very urgent for me.

      Thank You,
      Ravi kumar.