Thanks Bob, that's what I was looking for. Works great now. -- Josh
-----Original Message----- From: transfer-dev@googlegroups.com [mailto:transfer-...@googlegroups.com] On Behalf Of Bob Silverberg Sent: Wednesday, February 11, 2009 9:31 AM To: transfer-dev@googlegroups.com Subject: [transfer-dev] Re: Column name appears more than once on save It sounds like the systemid is the column that is being used in the one-to-many. In that case you probably need to do: <compositeid> <parentonetomany class="classOfParentOneToMany" /> <property name="subjectid" /> </compositeid> and then remove: <property name="systemid" type="numeric" /> This is discussed here: http://docs.transfer-orm.com/wiki/Using_Composite_Keys.cfm Bob On Wed, Feb 11, 2009 at 12:18 PM, Josh Nathanson <joshnathan...@gmail.com> wrote: > > Hey all, > > Got an object that looks like this: > > <object name="identityfield" table="IdentityFields"> > <compositeid> > <property name="systemid" /> > <property name="subjectid" /> > </compositeid> > <property name="systemid" type="numeric" /> > <property name="subjectid" type="numeric" /> > <property name="name" type="string" /> > </object> > > When I do a get, load up some data using set methods, and then try to save > it, however, I get the error: > > "Column name 'systemId' appears more than once in the result column list." > > And the sql looks like this: > > UPDATE IdentityFields SET systemid = (param 1) ,subjectid = (param 2) ,name > = (param 3) ,systemid = (param 4) WHERE systemid = (param 5) AND subjectid = > (param 6) > > I don't get where this extra systemid column is coming from. This object is > a child in a one-to-many relationship, but that should not be coming into > play here as I am just working with the identityfield object in this case. > > -- Josh > > > > > > > > > -- Bob Silverberg www.silverwareconsulting.com --~--~---------~--~----~------------~-------~--~----~ Before posting questions to the group please read: http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer You received this message because you are subscribed to the Google Groups "transfer-dev" group. To post to this group, send email to transfer-dev@googlegroups.com To unsubscribe from this group, send email to transfer-dev-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en -~----------~----~----~----~------~----~------~--~---