Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Felipe Martín Santos
Ok Andrus, I've discovered how attach files... When you have a free moment, check it out please, if you have troubles understanding something... ask me!! Best regards!! 2012/10/23 Felipe Martín Santos > Muchísimas gracias Andrus!! > > I've created https://issues.apache.org/jira/browse/CAY-1751

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Felipe Martín Santos
Muchísimas gracias Andrus!! I've created https://issues.apache.org/jira/browse/CAY-1751 is possible upload a file? or I must write the code in the Description Frame?? 2012/10/23 Andrus Adamchik > > Andrus, you can test this probleme if you have a similar example (more or > > less), and check

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Felipe Martín Santos
Yes Emmanuelle, we use the Custom Sequence Strategy (we generated all the schema with with Cayenne Modeler), the schema has many tables and we do many operations without problems, with have the problem only in the case that I've exposed (Emanuelle la strategia è stata fatta dal inizio e le sequen

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Emanuele Maiarelli
Did you specify the primary key generation strategy? As far as i remember i had similar errors on oracle dued to not having specified the sequence name(and cached size) On Tue, 23 Oct 2012 13:57:50 +0200, Felipe Martín Santos wrote: > Sorry but doesn' work :-( > > MY RELATIONSHIPS: > >

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Andrus Adamchik
> Andrus, you can test this probleme if you have a similar example (more or > less), and check what I say. Yes, if you can provide a mapping project demonstrating an issue (no need for Java classes), I'll take a look. Feel free to use our Jira for that: https://issues.apache.org/jira/browse/CAY

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Felipe Martín Santos
Sorry but doesn' work :-( MY RELATIONSHIPS: db-attribute-pair source="ID_PIECE_OF_GROUND" target="ID_PIECE_OF_GROUND"/> * THE CODE FOR INSERT (We use Generic Persistent Class of Cayenne) Expression exp = ExpressionFactory.matchExp("idPieceOf

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Andrus Adamchik
Looking at it again, I think you need to make both USE.CD_USE and ENCLOSURE.CD_USE columns PKs in Cayenne model. On the ENCLOSURE side, you'd keep an ObjAttribute for this newly designated PK column (so your Java could would stay the same, and you'll keep calling 'setUse'). Of course this shoul

Re: Possible bug in cayene 3.0.2 to set relationships???

2012-10-23 Thread Felipe Martín Santos
Thank you very much Andrus, but your solution doesn't work. I still believe that is a debug of cayenne. To do that you've said me: * To allow the Cayenne modeler check "to dep Pk" in the relationship slave_table (ENCLOSURE) --> master_table (USE), I need before check the FK (CD_USE) in the slave