Hi,
I am trying a similar JPQL:
select c.name, count(distinct d) as od from Corporation c, IN(c.divisions) d
group by c.name order by od
In the trunk level code, it works fine. The generated SQL is:
SELECT t0.CORPORATION_NAME, COUNT(DISTINCT t1.ID) AS od FROM
user318.CORPORATION
t0 INNER
Hi,
I am able to see the problem you reported. Note that em.merge(entity)
returns a managed object and Verfahrenstatus gets merged internally/implicitly
by OpenJPA along with Verfahrendokument. It appears that OpenJPA fail to set
the
Id for Verfahrenstatus after merge. I will
);
s1.setStatus(2);
d1.addStatus(s1);
//em.merge(d1);
em.getTransaction().commit();
Regards,
Fay
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
Sent: Wed, September 29, 2010 9:57:28 AM
Subject: Re: @OneToMany list
Hi,
Making the superclass an embeddable should not prevent it from being
subclassed by other entities.
Regards,
Fay
- Original Message
From: llchen llc...@sympatico.ca
To: users@openjpa.apache.org
Sent: Tue, July 13, 2010 3:42:26 AM
Subject: Re: JPA genereates non-exist id column
You can try @PersistentCollection
- Original Message
From: llchen llc...@sympatico.ca
To: users@openjpa.apache.org
Sent: Tue, July 13, 2010 10:22:57 AM
Subject: Re: JPA genereates non-exist id column in the select statement
Sorry I forgot to mention that I am using JPA 1.0 and
Since the underlying table does not have primary key, you might want to make
VoParagraphData an embeddable:
@Embeddable
public class VoParagraphData implements Serializable {
In the VoDocumentTemplateGroupObjectData, you can make the collection of
VoParagraphData an ElementCollection:
=DTG_OBJ_ID),
@JoinColumn(name=PARA_VNBR, referencedColumnName=DTG_OBJ_VNBR)
}
)
protected CollectionVoParagraphData paraObjects;
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
Sent: Mon, July 12, 2010 4:09:31 PM
Subject: Re: JPA
Hi,
Which version of OpenJPA are you using? Using the trunk level code, I
got the generated SQL as:
4306 testSubquery TRACE [main] openjpa.Query - Executing query: [select o
from Role as o where (lower(o.name) like :search or lower(o.printCode) like
:search) and o.id not in (select
Hi,
You can use @AttributeOverride to override the mapping of an embeddable
field.
http://openjpa.apache.org/builds/1.0.2/apache-openjpa-1.0.2/docs/manual/jpa_overview_mapping_field.html#jpa_overview_mapping_embed
Fay
- Original Message
From: stlecho stle...@gmail.com
To:
Hi,
I still could not reproduce the NPE problem using your entities. The
following is the url for join fetch.
http://openjpa.apache.org/builds/1.0.2/apache-openjpa-1.0.2/docs/manual/jpa_overview_query.html#jpa_overview_join_fetch
- Original Message
From: Zhanming Qi
Hi, Chris,
Can you provide the entity definitions?
Thanks,
Fay
- Original Message
From: C N Davies c...@cndavies.com
To: users@openjpa.apache.org
Sent: Sun, April 25, 2010 2:51:56 AM
Subject: IOB Error
This application has been running just fine for the last few months,
suddenly I
+1.
- Original Message
From: Donald Woods dwo...@apache.org
To: d...@openjpa.apache.org
Cc: users@openjpa.apache.org
Sent: Mon, April 19, 2010 11:45:53 AM
Subject: [VOTE] Apache OpenJPA 2.0.0 release candidate #2
I've staged a RC2 for OpenJPA 2.0.0 based on r935683 of the code in the
Hi,
I tried the following jpql on openjpa trunk code:
String jpql1 = SELECT k.keyname, SUM(k.keyval) FROM KeyGenEntity k
GROUP BY k.keyname ORDER BY SUM(k.keyval) DESC;
The generated sql is:
SELECT t0.KEYNAME, SUM(t0.KEYVAL), SUM(t0.KEYVAL) FROM KEYGEN t0 GROUP BY
+1
Thanks!
On Tue, Mar 23, 2010 at 9:36 PM, Donald Woods dwo...@apache.org wrote:
I've staged a release candidate for OpenJPA 2.0.0 Beta 3 based on
r926797 of the code in the 2.0.x branch, which was tagged in svn to:
https://svn.apache.org/repos/asf/openjpa/tags/2.0.0-beta3/
Release
As Jerry points out, ElementCollection is a standard JPA 2.0 annotation, while
PersistentCollection is OpenJPA-specific. Also, ElementCollection can be
applied to Collection and Map for embeddables or basic types, while
PersistentCollection can only apply to Collection, for Map, you need to use
hi Jerry,
I could not reproduce this problem and I am using the trunk level code.
11256 callback TRACE [main] openjpa.jdbc.SQL - t 16785420, conn 20448186
executing prepstmnt 2721032 INSERT INTO EntityA (id) VALUES (?) [params=(int) 1]
11276 callback TRACE [main] openjpa.jdbc.SQL -
Hi Jerry,
Ok, I take out the OneToOne annotation, and employ inheritance as shown
below. The test works just fine. I don't see unmanaged object exception.
(1)
@Entity
public class SimpleEntity {
@Id
private long id;
public long getId() { return id; }
public void setId(long
Hi,
As the exception clearly indicates, adding Cascade attribute should fix this
unmanaged object problem, and the insert should work:
@Strategy(MyPointHandler)
@OneToOne(cascade=CascadeType.ALL)
private MyPoint custom;
Since you did not provide MyPoint.java, the following
Hi,
I noticed that you have name field in your Customer.java and
ValuedCustomer.java. This field in both classes is mapped to the same column in
the same table. Since ValuedCustomer inherits from Customer, I am wondering why
you need to have a separate name field in the ValuedCustomer. If
TABLE GREATCUSTOMERDATA (ID VARCHAR(254), GC_ID VARCHAR(254))
Fay
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
Sent: Thu, February 25, 2010 11:11:57 AM
Subject: Re: JPA adding class name to join column name
Hi,
I noticed that you have name field
Message
From: KARR, DAVID (ATTCINW) dk0...@att.com
To: users@openjpa.apache.org
Sent: Sat, January 23, 2010 11:28:15 AM
Subject: RE: Named query doesn't translate table/column names properly, UNLESS
it's run after an identical inline query
-Original Message-
From: Fay Wang [mailto:fyw
As you described, it seems that the information specified in the orm.xml is not
picked up by OpenJPA. This issue seems resolved in JIRA-859 in the trunk code
and 1.3.x branch.
Fay
- Original Message
From: KARR, DAVID (ATTCINW) dk0...@att.com
To: users@openjpa.apache.org
Sent: Fri,
I have seen this problem before, but somehow it went away. I am using your
entity definition but could no longer reproduce the problem. Using java
decompiler, the following is my pcCopyKeyFieldsToObjectId in EmailAddress. Can
you post your problematic pcCopyKeyFieldsToObjectId?
public void
For JPA 2.0 (OpenJPA trunk), the map key does not need to be a field in the
target entity. For example, please see the test case in
org.apache.openjpa.persistence.jdbc.maps.*.
- Original Message
From: KARR, DAVID (ATTCINW) dk0...@att.com
To: users@openjpa.apache.org
Sent: Tue,
Hi,
You don't need to put generatedValue annotation for the version field.
Openjpa will keep track of the version for you.
@Version
public long getVersion() {
return this.version;
}
- Original Message
From: yokenji kenji2...@gmail.com
To: users@openjpa.apache.org
Sent:
Hi,
I tried the following using openjpa trunk, and it works fine. I will
try it using openjpa 1.2.
Query q =
em.createQuery(Select m from Manager m, IN (m.employees) emps
where emps = :emp);
Employee emp = new Employee();
emp.setId(1);
Running against openjpa 1.2, I got the same error as you did. Apparently, this
problem is fixed in the trunk code.
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
Sent: Mon, November 9, 2009 9:09:04 AM
Subject: Re: Unexpected ArgumentException using
!
Neither of those, I just execute the program twice. So, it's not about
the managed / detached entities.
Fay Wang wrote:
The em.merge will return the merged entity.
EntityA mergedEntity = em.merge(newEntity);
During your second merge call, did you call
em.merge(mergedEntity
The em.merge will return the merged entity.
EntityA mergedEntity = em.merge(newEntity);
During your second merge call, did you call
em.merge(mergedEntity)
or
em.merge(newEntity)?
Fay
- Original Message
From: Constantine Kulak c...@mail.by
To: users@openjpa.apache.org
You can call the following API to limit the number of rows returned by the
query:
Query.setMaxResults(maxResults);
- Original Message
From: Michael Simons michael.sim...@optitool.de
To: users@openjpa.apache.org
Sent: Thu, October 29, 2009 11:13:12 AM
Subject: Limit the size of
Hi,
You might want to try:
Select p.firstname,
Case v.type WHEN 'v1' THEN v.type
WHEN 'v2' THEN 'null'
ELSE 'null' END +
from Patient p left join p.vaccinCollection v
However, this approach still requires post-processing of
By default, the max fetch depth is set to -1 for no limit. However, this graph
is an indirect recursion, i.e., from State - Transition - State. I think
this makes Openjpa to stop prematurely...
Fay
- Original Message
From: calin014 calin...@gmail.com
To: users@openjpa.apache.org
().addFetchGroups(State_OutgoingTransitions,
State_IncomingTransitions);
Flow flow = entityManager.find(Flow.class, id);
And the query is affected because, if i don't add the fetch groups, only the
first state gets loaded into memory.
Fay Wang wrote:
By default, the max fetch depth is set to -1
);
jfp.addFetchGroup(Transition_ToState);
jfp.addFetchGroup(Transition_FromState);
State s1 = em.find(State.class, 2);
The resulting s1 should contain the complete graph.
Regards,
Fay
:
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
This feature is newly added in JPA 2.0 spec. I don't think it will be added to
1.2.x release.
- Original Message
From: Matthew Adams matt...@matthewadams.me
To: users@openjpa.apache.org
Sent: Friday, September 4, 2009 8:35:32 AM
Subject: Re: Collection of enums: supported yet?
This is currently supported in openjpa trunk.
@ElementCollection
@Enumerated(EnumType.STRING)
protected ListCreditRating cr = new ArrayListCreditRating();
where
public enum CreditRating { POOR, GOOD, EXCELLENT };
Regards,
Fay
- Original Message
From: Matthew
Sorry, I probably confuse you about the JPQL and native (SQL) query.
The CollectionString approach will work with JPQL, but not with SQL (native
query, regardless it is named or not).
For JPQL, the Query object is created in the following way:
Query q = em.createQuery(select e from Entity1 e
Hi,
For native query:
String sql = select count(e.eid), e.* from Entity e, Property p where
e.eid=p.refersTo and p.type IN ( ?1 ) group by e.eid order by count(e.eid)
desc;
As you observed, the following parameter setting will work, since you have only
one parameter marker:
parameters accordingly. The push-down sql will look like:
select ... where ... p.typeIN (?1, ?2, ?3)
-Fay
- Original Message
From: Fay Wang fyw...@yahoo.com
To: users@openjpa.apache.org
Sent: Monday, August 31, 2009 8:59:56 PM
Subject: Re: OpenJPA1.2.2 - NativeQuery
-291
That's a pity since more and more DBs support hierarchical queries natively
(connect-by in oracle, with() in db2, recently postgres) and gives huge
performance kick where complicated traversal is needed in a single query.
Cheers
Krzysztof
Fay Wang wrote:
Hi,
Can you try making
Hi Krzysztof,
I could not reproduce your problem using my own test case. From your
annotation, I would suppose that tsType is a persistent field of the map value,
and it is of EnumType. Could you provide your domain model for further
investigation?
Regards,
Fay
- Original Message
Hi Krzysztof,
Given your description below, I am able to reproduce this problem. I will
take a look at it. Thanks!
Regards,
Fay
- Original Message
From: Krzysztof yaz...@gmail.com
To: users@openjpa.apache.org
Sent: Wednesday, August 19, 2009 11:38:36 AM
Subject: Re: Enum as a
to the enum as a dirty hack but it's not doable
of course.
Good luck!
Krzysztof
Fay Wang wrote:
Hi Krzysztof,
Given your description below, I am able to reproduce this problem. I
will take a look at it. Thanks!
Regards,
Fay
- Original Message
From: Krzysztof yaz
@openjpa.apache.org
Sent: Wednesday, August 19, 2009 1:28:44 PM
Subject: Re: Enum as a Key in a Map
Thank you Fay,
Probably ApplicationIdTool could be updated as well - it actually creates
some code for such cases, but not digestible by the compiler.
Best regards,
Krzysztof
Fay Wang wrote:
Hi Krzysztof
Hi,
Can you try making AbstractModel an Entity instead of MappedSuperClass,
and making this class a concrete class as shown below?
// abstract class that has common identity and some additional fields, it is
//a Key in a map
@Inheritance(strategy = InheritanceType.JOINED)
@Entity
- Original Message
From: David Minor davemi...@gmail.com
To: users@openjpa.apache.org
Sent: Monday, June 29, 2009 5:23:25 PM
Subject: SQL generation for OneToMany object graph
Hi,
If I have a deep object graph with a root element that has OneToMany
relationships with other
Hi, it seems that you are using the Join strategy for your eager fetch mode.
Can you try
parallel?
property name=openjpa.jdbc.EagerFetchMode value=parallel/
Fay
- Original Message
From: David Minor davemi...@gmail.com
To: users@openjpa.apache.org
Sent: Monday, June 29, 2009
in the object graph that would
prevent this behavior?
-Original Message-
From: Fay Wang [mailto:fyw...@yahoo.com]
Sent: Thursday, July 02, 2009 9:19 AM
To: users@openjpa.apache.org
Subject: Re: SQL generation for OneToMany object graph
Hi, it seems that you are using the Join
Hi,
I used your annotation and my test case runs fine.
Given your pkColumnName = table_name, openjpa internally makes this
column name valid for a given database. This code is in ValueTableJDBCSeq:
protected Column addPrimaryKeyColumn(Table table) {
DBDictionary dict =
To: users@openjpa.apache.org
Sent: Monday, June 22, 2009 9:58:33 AM
Subject: Re: Problem with @TableGenerator [OpenJPA 1.2.2]
Hi Fay Wang,
thanks for your reply. As you probably already guessed beacuse of the name
jdo_keygen, we are
porting an application that was based on JDO to JPA. So the table
The number of queries depends on the fetch strategy. Currently there are two
fetch strategy:
property name=openjpa.jdbc.EagerFetchMode value=join/
property name=openjpa.jdbc.EagerFetchMode value=parallel/
If you are using join strategy, in the example that A contains oneToMany
relation to B,
Fay Wang wrote:
The NPE is because the SituationDA is inherited from
CashBaseEntity and
CashBaseEntity does not have Id class. JIRA 873 is
open to address this
issue.
Regards,
Fay
--- On Sat, 1/24/09, Drifter pioneer...@yahoo.com
wrote:
From: Drifter pioneer
Hi Kevin,
What about SolidDB? The memory-based relational database?
--- On Fri, 5/15/09, Kevin Sutter kwsut...@gmail.com wrote:
From: Kevin Sutter kwsut...@gmail.com
Subject: Re: Database support
To: users@openjpa.apache.org
Date: Friday, May 15, 2009, 2:09 PM
Okay, so I'm looking at our
Hi Earnie,
For your named query:
SELECT p FROM Person p ORDER BY p.me DESC, p.lastName, p.firstName,
p.middleName, p.lineage.description
If you take out order by p.lineage.description, the push-down SQL will
become left outer join.
Fay
--- On Tue, 4/28/09, Earnie Dyke
in a query.
-Jeremy
[1] https://issues.apache.org/jira/browse/OPENJPA-1043
On Mon, Apr 20, 2009 at 4:33 PM, Fay Wang fyw...@yahoo.com
wrote:
Hi,
According to openjpa manual:
Unlike true entities, you cannot query a mapped
superclass
http://openjpa.apache.org/builds/latest/docs
Hi,
Here is a simple example:
(1) EntityA.java:
package queryTest;
import javax.persistence.*;
@SqlResultSetMapping(name=ResultCMapping,
entitie...@entityresult(entityClass=ResultC.class)}
)
@NamedNativeQuery(
name=nativefindAandB,
query=SELECT a.id, a.name,
, Fay Wang fyw...@yahoo.com
wrote:
Just found that in JPA 2.0 Proposed Final Draft (March
13, 2009):
Spec 2.11.2:
A mapped superclass, unlike an entity, is not
queryable and cannot be
passed as an argument to EntityManager or Query
operations.
--- On Tue, 4/21/09, Jeremy Bauer
Can you turn on the trace :
property name=openjpa.Log value=File=c:/trace.log, DefaultLevel=TRACE /
and attach the trace file for further investigation?
-Fay
--- On Thu, 4/16/09, Georgi Naplatanov go...@oles.biz wrote:
From: Georgi Naplatanov go...@oles.biz
Subject: Optimistic locking
.
So I am willing to jump through hoops for a work around even it means
changing the identity type or doing lots of flushes or something else like
that. Just wondering what my options are.
I already tried doing flushes. Maybe I need to do a refresh too?
- Paul
On 4/7/2009 1:51 PM, Fay
The fix is in JIRA-1004. I only checked in the fix to trunk, not 1.2.x, though.
-Fay
- Original Message
From: Paul Copeland t...@jotobjects.com
To: users@openjpa.apache.org
Sent: Tuesday, April 7, 2009 12:34:05 PM
Subject: Re: Identity class and parent/children entity relationship
It appears that openjpa currently does not support MapKey annotation applied to
a relation field. This, however, is not explicitly stated in the user guide or
JPA 2.0 spec. Please open a JIRA for it. Thanks!
- Original Message
From: Michael Vorburger mvorbur...@odyssey-group.com
and MapKeyJoinColumns annotations are used to specify the
column mappings for the map key. ... would anybody be able to try my example
as a test on the OpenJPA for JPA 2.0 version?
-Original Message-
From: Fay Wang [mailto:fyw...@yahoo.com]
Sent: Thu 4/2/2009 10:05 PM
To: users@openjpa.apache.org
Subject
You can use @AttributeOverrides to map the fields in the embeddable to the same
columns.
-Fay
--- On Tue, 3/24/09, Adam Hardy adam@cyberspaceroad.com wrote:
From: Adam Hardy adam@cyberspaceroad.com
Subject: usage of embeddable
To: users@openjpa.apache.org
Date: Tuesday, March
I could not reproduce your problem in OpenJPA 1.2.x. What revision are you
using? From the stack trace, you might want to set
property name=openjpa.jdbc.QuerySQLCache value=false /
to see if it works.
-Fay
--- On Tue, 3/24/09, Richard Rak richard@gmail.com wrote:
From: Richard
Hi Fazi,
I found that by putting
TimeZone.setDefault(TimeZone.getTimeZone(Etc/UTC));
to make your java app in UTC time zone (see below in testDate), openjpa will
store the dates in UTC in the database.
public void testDate(){
object representing that
TimeZone.
If you change the default timezone to UTC (or Moscow, etc.)
then all the other Calendar objects that are meant to
represent the default Locale will be wrong!
- Paul
On 3/17/2009 2:15 PM, Fay Wang wrote:
Hi Fazi,
I found that by putting
does that
happen?
Fay Wang on 17/03/09 23:41, wrote:
To my knowledge, as far as DB2 is concerned, DB2 v9
and below does not have timestamp with time zone
data type. The value stored in the DB2 timestamp column is
without time zone information. It is up to the application
to determine
Hmmm. I could not reproduce the error using your domain model in 1.2.0 and
trunk. Attached is the test case. Could you run it to see it passes?
Regards,
Fay
--- On Tue, 3/3/09, Michael Vorburger mvorbur...@odyssey-group.com wrote:
From: Michael Vorburger mvorbur...@odyssey-group.com
and you'll see the
problem! Do you confirm?
Regards,
Michael
-Original Message-
From: Fay Wang [mailto:fyw...@yahoo.com]
Sent: Tuesday, March 03, 2009 10:21 PM
To: users@openjpa.apache.org
Subject: Re: ArrayIndexOutOfBoundsException in
org.apache.openjpa.util.ApplicationIds
The NPE is because the SituationDA is inherited from CashBaseEntity and
CashBaseEntity does not have Id class. JIRA 873 is open to address this issue.
Regards,
Fay
--- On Sat, 1/24/09, Drifter pioneer...@yahoo.com wrote:
From: Drifter pioneer...@yahoo.com
Subject: @MappedSuperClass Cause
Hi Mike,
I could not reproduce your problem. I used your entity definitions with the
following modification:
(1) put @Entity to the Test class
(2) made Test class an abstract class,
After the insert, my table has 5 rows in it:
select id_column, CONTAINING_OBJ_ID from test_table
Hi Mike,
I could not reproduce your problem. I used your entity definitions with the
following modification:
(1) put @Entity to the Test class
(2) made Test class an abstract class,
After the insert, my table has 5 rows in it:
select id_column, CONTAINING_OBJ_ID from test_table
.containing_obj_id = ? [params=(int) 1]
--- On Mon, 12/8/08, Fay Wang [EMAIL PROTECTED] wrote:
From: Fay Wang [EMAIL PROTECTED]
Subject: Re: Help - Single table inheritance not working with one-to-many
collection
To: users@openjpa.apache.org
Cc: Fay Wang [EMAIL PROTECTED]
Date: Monday
set any values for that column in your table when running
your example
(thanks for doing that, btw :) If 2 of your rows have the
discriminator set
to 'S', then you should only get 2 TestChild1s back
in the getTestChildren()
method. I'm getting 5.
Thanks,
-Mike
Fay Wang wrote:
Hi
or am I misusing it?
I am using openjpa-1.0.2.jar, with the Enhancer.
Thanks again,
-Mike
Fay Wang wrote:
Hi Mike,
I do have the discriminator column. I have the
following columns in my
test_table:
Column name
--
ID_COLUMN
COLUMN_A
SITE_ID
Hi,
You might want to try native query as follows:
Query query = em.createNativeQuery(SELECT id FROM table WHERE MONTH(
DATE(timestamp1) - DATE(timestamp2) ) 3 )
Fay
--- On Thu, 11/20/08, du27177 [EMAIL PROTECTED] wrote:
From: du27177 [EMAIL PROTECTED]
Subject: Timestamp
To:
,CascadeType.DELETE_ORPHAN})
private SetAssignedActivity assignedTo = new
HashSetAssignedActivity();
..}
Regards,
Eli
Fay Wang wrote:
Hi,
In your test case, you have OneToMany relation from
Activity to
AssignedActivity. The mappedBy attribute in the
OneToMany relation should
Can you turn on the trace?
-Fay
--- On Tue, 11/4/08, John VanAntwerp [EMAIL PROTECTED] wrote:
From: John VanAntwerp [EMAIL PROTECTED]
Subject: WebSphere @OneToOne problem
To: users@openjpa.apache.org
Date: Tuesday, November 4, 2008, 9:14 PM
We have an entity that inherits from another
WebSphere Application Server Version 6.1 Feature Pack
for EJB 3.0
Version 6.1.0.13
ID EJB3
Build Level f0747.05
Build Date 11/30/07
Installed Product
Fay Wang [EMAIL PROTECTED]
Fay Wang [EMAIL PROTECTED]
10/27/2008 10
Application Server Version 6.1 Feature Pack
for EJB 3.0
Version 6.1.0.13
ID EJB3
Build Level f0747.05
Build Date 11/30/07
Installed Product
Fay Wang [EMAIL PROTECTED]
Fay Wang [EMAIL PROTECTED]
10/27/2008 10:10 AM
Hi,
I could not reproduce this problem against DB2. Which database are you
using? also,can you post your persistence.xml to see if there is any special
setting?
Fay
--- On Mon, 10/27/08, sbedoll [EMAIL PROTECTED] wrote:
From: sbedoll [EMAIL PROTECTED]
Subject: Native Query: Update fails
) {
this.fsbCde = fsbCde;
}
public String getXfrtypCde() {
return xfrtypCde;
}
public void setXfrtypCde(String xfrtypCde) {
this.xfrtypCde = xfrtypCde;
}
}
Fay Wang wrote:
Hi Enrico,
I made up TblItmtyp
The class TblTrkdet is also missing...
--- On Fri, 10/3/08, Fay Wang [EMAIL PROTECTED] wrote:
From: Fay Wang [EMAIL PROTECTED]
Subject: Re: Exception in SQLBuffer.java on OpenJPA 1.3.0-SNAPSHOT
To: users@openjpa.apache.org
Date: Friday, October 3, 2008, 8:34 AM
Hi Enrico,
Could you
Hi Enrico,
I made up TblItmtyp and TblTrkdet and ran a test case with the code snippet
you provided. It worked just fine. You mentioned that the test case works fine
with 1.2.0. Can you provide the generated sql on 1.2.0?
Regards,
Fay
--- On Fri, 10/3/08, egoosen [EMAIL PROTECTED] wrote:
Hi,
I can reproduce this problem. Please open a JIRA for this problem. Thanks!
-Fay
--- On Fri, 9/19/08, egoosen [EMAIL PROTECTED] wrote:
From: egoosen [EMAIL PROTECTED]
Subject: OpenJPA 1.2.0 Bug on FetchType.EAGER
To: users@openjpa.apache.org
Date: Friday, September 19, 2008, 12:49
());
}
}
--- On Fri, 9/19/08, Fay Wang [EMAIL PROTECTED] wrote:
From: Fay Wang [EMAIL PROTECTED]
Subject: Re: OpenJPA 1.2.0 Bug on FetchType.EAGER
To: users@openjpa.apache.org
Date: Friday, September 19, 2008, 9:14 AM
Hi,
I can reproduce this problem. Please open a JIRA for
this problem
Here is an example:
@Entity
public class EntityA {
@Id private int id;
@Enumerated( EnumType.ORDINAL )
private Measure measure;
public Measure getMeasure() {
return measure;
}
public void setMeasure(Measure measure) {
this.measure = measure;
Yes, you are right. This problem is caused by a relation field being annotated
as a primary key and foreign key. You might want to apply the patch I put in
JIRA-679. Before the patch:
CREATE TABLE D (id VARCHAR(254) NOT NULL, a VARCHAR(254), C_CID VARCHAR(254),
C_CM_CMID VARCHAR(254),
Hi,
You might want to add @ElementDependent as shown below:
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY,
mappedBy = parent)
@OrderBy(value = ordr)
@ElementDependent
private ListChild children = new ArrayListChild();
so that when you do:
I can reproduce this problem against DB2. It looks like that this problem is
generic, independent of the backend. The jdbc trace shows:
7828 CustomerOrder TRACE [main] openjpa.jdbc.SQL - t 1090273532, conn
582492856 executing prepstmnt 1346129980 INSERT INTO EntityA (id, amt,
creationts,
Hi,
Omitting the not null from column definition will make the test case work.
However, the insert statement as shown below in the jdbc trace will insert null
into the creationts column, and the current timestamp (default by db) will
never get inserted into the table. Is this the expected
Hi,
Please do the following:
select j from job j
-fay
--- On Tue, 7/8/08, tao [EMAIL PROTECTED] wrote:
From: tao [EMAIL PROTECTED]
Subject: Query problem with open jpa 1.0.2
To: users@openjpa.apache.org
Date: Tuesday, July 8, 2008, 3:30 PM
Hi, I'm working on a project using
Hi,
My patch is for relationships annotated with foreign key on delete cascade.
Can you provide a test case that fails for insert or update due to foreign key
violation?
-fay
--- On Fri, 7/4/08, Beniamin Mazan [EMAIL PROTECTED] wrote:
From: Beniamin Mazan [EMAIL PROTECTED]
Subject:
Hi,
From the stack trace:
...
org.apache.openjpa.jdbc.kernel.PreparedStatementManagerImpl.flush(PreparedStatementManagerImpl.java:73)
at
org.apache.openjpa.jdbc.kernel.OperationOrderUpdateManager.flushPrimaryRow(OperationOrderUpdateManager.java:162)
at
Hmmm. Here is my test case and it works fine. Four classes are listed:
(1) TblPdtbnf0.java
(2) TblPdtbnfId.java
(3) TblScmpdt0.java
(4) Test0.java
You might still want to try it? :=))
-f
(1) TblPdtbnf0.java
package insert;
import
ok. I can reproduce your problem. Let me take a look.
-f
--- On Sat, 6/14/08, Enrico Goosen [EMAIL PROTECTED] wrote:
From: Enrico Goosen [EMAIL PROTECTED]
Subject: Re: @OneToMany/@ManyToOne, Bidirectional, Composite Key
To: users@openjpa.apache.org
Date: Saturday, June 14, 2008, 5:46 AM
Hi Ernico,
The cause of the problem is not the composite primary key but the
mapping of the primary key column and join column in the child table:
(1) in the parent class TblScmpdt:
the primary key: scmpdtId (the column: SCMPDT_ID)
(2) in the child class
the composite primary key: pdtbnfId
Hi Enrico,
Here is my example, and it runs fine:
(1) EntityA.java:
@Entity
public class EntityA {
@Column(name=A_ID)
@Id private int id;
private String name;
@OneToOne(fetch = FetchType.LAZY)
@JoinColumns([EMAIL PROTECTED](name=B_ID,
Hi Valentin,
Did you enhance your entity class NavPoint before executing your query?
--- On Thu, 5/29/08, Valentin BUERGEL [EMAIL PROTECTED] wrote:
From: Valentin BUERGEL [EMAIL PROTECTED]
Subject: ArgumentException
To: users@openjpa.apache.org
Date: Thursday, May 29, 2008, 6:54 AM
Hi!
Hi Mike,
Your super class EntityBase is annotated as @MappedSuperclass. Your
Translatable class which inherits from EntityBase has inheritance strategy of
TABLE_PER_CLASS. Since MappedSuperclass itself is not a persistence class and
can not act in the capacity of an entity, it does not have
1 - 100 of 104 matches
Mail list logo