4 Replies Latest reply: Jan 25, 2012 5:21 AM by ecchuckles RSS

    how to push child record using beanproxy?

    ecchuckles Community Member

      I've been using the hibnerateassembler to update  parent and insert child record  into db on the lcds server and then using the beanproxy to try to push the updates back to the client. The parent update is received by the client but not the child record;

       

      here's what I'm currently trying to do

       

      BeanProxy proxy = new BeanProxy(parent)

      parent.setvalue("col1",val);

      parent.setValue("col2",val2)

       

      BeanProxy bp = new BeanProxy(parent.getValue("child"));

      bp.setValue("col1",child.val);

      bp.setValue("col2",child.val);

       

      DataServiceTransaction dtx = DataServiceTransaction.begin(false);    

        dtx.createItem(ChildService,child);

         dtx.updateItem(ParentService, parent, oldParent, null);

         dtx.commit(); // done telling lcds

       

       

      what am I doing wrong?

      thanks in advance

      chuckles