Thank`s I`ve setted this flag, but it`s still not working well Right now I`m getting such query at the server
update items set order_id=null where order_id=? Don`t know why it`s trying to do such a update. It`s true that items aren`t sended back to the server - but why it`s trying to remove them ? BTW. I`ve got some other question about updating/inserting items. Is there a way to simplifie this operation ? Right now LCDS or Hibernate is loading each referenced object - than doing operation (insert/update) and then selecting referenced objects again. When I`m adding new object through addItem - Hibernate already have all foreign key values - so can I somehow make it to use them , except of loading items ? Regards > > You probably want to set the paged-updates=true flag on that association tag. This controls whether changes to collections are sent with the parent item or not. When this is "true", if you modify that collection only the differences are sent. You can't do conflict detection in this mode as well. > > In 2.6.1 the best way to turn this option on is to either set: load-on-demand=true with lazy=false, or page-size="xx" with lazy=true or false. These both turn on paged-updates automatically. > > Jeff > > From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of piotrchruscielewski > Sent: Wednesday, November 26, 2008 12:21 AM > To: [email protected] > Subject: [flexcoders] LCDS / Hibernate - How tu update only one field (without sending all references) > > > Hi > > I`m doing some bigger problem with LCDS / Hibernate annotation and > still I`m reaching some problems. > > Lets suppose such structure > > public class Order > ( > @Id > private int id; > > private String code; > > @OnetoMany(fetch=FetchType.EAGER) > private Set<OrderItem> orders; > > getters, setters.. > > ) > > So it`s simple OneToMany relation - AS3 class is proper constructed > with orders:ArrayCollection - everything works fine > > But the case it that I want the 'orders' field to be read only > (because my app will never change it - it`s even view-based not table ). > > So i don`t want Flex to send this field back to the server , while > something in Order item changes. My application should change only the > code value. Right now when I`m changing code value - Flex is sending > whole orders array , and is trying to update it. > > Can I set somehow 'read-only' flag in Hibernate/LCDS ? setting it in > data-management-config , in <metatada><one-to-many.. > doesn`t work. > > Maybe I should set this field [Transient] in AS3 ? > > Thanks > > Best regards >

