05-17-2013 1:56 PM
Hi there,
i'm working with generated persistent classes where I use object references to an other generated class.
My example:
The table OBJECT contains a foreign key of the table OBJECTTYPE. I generated them over the persistence manager in SE24 - and it works.
Now added another field over SE11 to the table OBJECT. Then I want to add this field as attribute to the persistence class belated.
If I want to activate the class I get an error: "Only methods of the superclass can be redefined".
I could not change atrributes of a class, which accesses object references to other persistent classes!? I have to generate everything again!?
Or I have to do some changes in the Agent or the Base Agent?
Thanks for some help,
Andreas
05-17-2013 2:05 PM
You just have to go back to the persistence screen and add the attribute.
05-17-2013 2:49 PM
Hi Claudio,
thanks for this very fast reply!
But I go back to the persistence screen and then I could see the new field of the table.
When I add this as an attribute I get the error - because in this class is an object reference of another class..
05-17-2013 3:01 PM
05-17-2013 3:17 PM
Ah, okay.
I want to redefine a class, which has a key/object reference of another class.
I think here is an other description of the problem - and a solution, but not while using the generator of persistent classes.
05-17-2013 3:57 PM
Hello Andreaz,
When you add new fields to the table after you have generated the Persistent class, you need to visit the "Persistent Representation" and include the newly added fields.
Thanks,
Naimesh Patel