ataContexts, so you may have a race condition when
you attempt to modify the query in the code. So you may want to clone the
query like that:
SQLTemplate localQuery = rawQuery.queryWithParameters(...);
localQuery.setpageSize(50);
Andrus
On Aug 6, 2008, at 6:35 AM, Jens Mayer wrote:
>
Hi,
i'm using Cayenne 2.0.4 with Oracle 10 and JDK 1.5.
Please have a short look at this code:
... dataCtx, myID are set...
SQLTemplate rawQuery =
(SQLTemplate)dataCtx.getEntityResolver().lookupQuery("myQuery");
Map params = new HashMap();
params.put("processID", myID);
rawQuery.setParameters
Hi,
I'm using the technique of copying datamaps (by Michael Gentry, look at
http://cwiki.apache.org/CAY/copying-datamaps.html).
Works fine as long as the configuration files are located in the filesystem. I
moved them into a package (following the hints at
http://cwiki.apache.org/CAYDOC/custom
Hi,
I'm trying to build a tree-like structure based on data in my db.
My table TMP_TRANSEDIT has a relationship to itself:
TMPTRANSEDIT_ID NUMBER(10) is the PK ... and
TMPTRANSEDIT_TMPTRANSEDIT_ID NUMBER(10) is used for the relationship to
the parent.
The tabledata is inserted by two querie
Hi,
I'm wondering about an error message:
"Can't perform lookup. There is more than one ObjEntity mapped to class
TmpAttredit"
This is the code (as simple as possible):
DataContext dataCtx =
SelectQuery query = new SelectQuery(TmpAttredit.class);
List result = dataCtx.performQuery(query)
Hi,
I am having a problem with date-parameter-binding in a SQLTemplate.
This is my coding:
public static void validate(DataContext dataCtx)
throws ParseException {
final Map para = new HashMap();
final SimpleDateFormat sdf =
new SimpleDateFormat("dd.MM. HH:mm:ss");
pa
Hi,
I am not sure if I understood the concept of user-defined transaction:
I am accessing two different db-schemas at the same time, using two
DataDomains, one for each schema.
Now I want to update data (synchronously) on both schemas with my own
user-defined transaction-scope.
I have to use
In my application, the user has the ability to switch between databases
(for testing purposes). He gets a little dialog, types in
user/password/db-name and under the hood, an appropriate
DataContext is built.
Works fine, but I want to test the correctness of what he typed in
BEFORE the next qu
Hi,
I'm using cayenne with oracle 9.2.0.3.0
The pk-attributes in my schema are automatically generated by
before-insert-triggers, so cayenne doesn't have to bother generating any
pk. Due to this, I set the PK Generation Strategy for all DbEntities
to "Database-Generated".
And here comes the