openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dp <lindap...@gmail.com>
Subject Re: CacadeType.Persist problem
Date Thu, 19 May 2011 05:45:19 GMT
Hi,

I have identified why the exception of
"org.apache.openjpa.persistence.ArgumentException: "test.openjpa.A.auxdata"
defines a target of "UID" for join column "PUID", but that target does not
exist in table "test.A"." happened.

org.apache.openjpa.jdbc.meta.MappingInfo.java, Line Number 1531,

 Column tcol = foreign.getColumn(targetName, false);

Should foreign columns be allowed to create (the second argument is true
instead of false) here if the target columns have not been mapped yet?

As for the second issue, still pending.

Regards,
Dapeng

On Thu, May 19, 2011 at 11:20 AM, Lin Dapeng <lindapeng@gmail.com> wrote:

> Hi Rick,
>
> Thanks for your reply.
>
> A simple test case has been created. This test case is to generate
> exception of "org.apache.openjpa.
> persistence.ArgumentException: "test.openjpa.A.auxdata" defines a target of
> "UID" for join column "PUID", but that target does not exist in table
> "test.A".", which I think it may be wrong to process meta data according to
> attribute name order, especially when there is secondary tables present. At
> least primary table should be processed before any secondary table being
> processed.
>
> As for the second problem, which secondary table can't be inserted, I think
> it might need to flush selective auto-generated foreign keys, before second
> row being inserted, so that, auto-generated value will be filled.
>
> This is my first time to create a junit test case. Sorry for the big
> package.
>
> Regards,
> Dapeng
>
>
> On Wed, May 18, 2011 at 9:41 PM, Rick Curtis [via OpenJPA] <
> ml-node+6377856-2082560565-335768@n2.nabble.com> wrote:
>
>> Will you please create a small, repeatable unit test so someone can
>> investigate this issue?
>>
>> Thanks,
>> Rick
>>
>> *Rick Curtis*
>>
>>
>> ------------------------------
>>  If you reply to this email, your message will be added to the discussion
>> below:
>>
>> http://openjpa.208410.n2.nabble.com/CacadeType-Persist-problem-tp6367387p6377856.html
>>  To unsubscribe from CacadeType.Persist problem, click here<http://openjpa.208410.n2.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=6367387&code=bGluZGFwZW5nQGdtYWlsLmNvbXw2MzY3Mzg3fC0xNjA1MTAxMjY1>.
>>
>>
>
>
>
> --
>
> Regards,
> Dapeng
>
>


-- 

Regards,
Dapeng


--
View this message in context: http://openjpa.208410.n2.nabble.com/CacadeType-Persist-problem-tp6367387p6380721.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message