I'm still trying to reuse prepared statements and from looking at the source
code of IBatis 2.3, it seems you need a SessionScope for it to work (It
seems the session scope holds the prepared statement cache).
I can't find anywhere in the code where a SessionScope is instanciated, how
do I
We have a problem filling objects with several '1 to many
relationships' in breadth from one single SQL statement.
On page 40 of the iBatis Data Mapper Developer Guide the 'groupBy'
construct is described as follows:
Using this approach, you can solve any N+1 problem of any depth or breadth.
You'll need a discriminator.
Larry
On 2/19/07, [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote:
I have a class named Message which has a type (REQUEST, CONFIRM) based upon
an enum. I want to be able to define the Message class as abstract and
define RequestMessage and ConfirmMessage classes.
Hi all,
I am developing an application which has to work with oracle and with
mysql.
I am using two different queries because in case the value x3=null and I
am using oracle I get an exception.
In case I use mysql I don't have any exception.
I would like to know if I made some mistake
ciao Giuseppe,
is it a copy and paste error or did you forget the insert keyword in
the oracle sql?
Giovanni
Hi all,
I am developing an application which has to work with oracle and with mysql.
I am using two different queries because in case the value x3=null and I
am using oracle
It is a copy and past error
-Messaggio originale-
Da: Giovanni Cuccu - CUP2000 [mailto:[EMAIL PROTECTED]
Inviato: lunedì 19 febbraio 2007 15.15
A: user-java@ibatis.apache.org
Oggetto: Re: handling null values
ciao Giuseppe,
is it a copy and paste error or did you forget the
Greetings Claudio,
We too have this problem with the latest two releases. If you use version
2.1.7.597 you should have no problems - hopefully you have not implemented
any new features like we had (and had to scramble to undo). Versions 2.2
and 2.3 will not handle what you are trying to do.
can you post the oracle error code plus java stack trace along the sql
executed from the ibatis log file?
Giovanni
It is a copy and past error
-Messaggio originale-
Da: Giovanni Cuccu - CUP2000 [mailto:[EMAIL PROTECTED]
Inviato: lunedì 19 febbraio 2007 15.15
A:
iBATIS groupBy support does not support two independant lists. This would
be a very difficult problem to solve and would require us to deal with
object identity - which we don't deal with now.
So with groupBy, you can have one and only one list that is automatically
populated. Other lists will
Hi Jeff,
I'm very confused. Our application has many examples of independent
lists as in Claudio's example. This worked until we implemented release
2.3. We then backed up to 2.2 with the same result and then regressed
back to 2.1.7.597 which does indeed work. We will have much work to do
..or you could use a rowhandler.
Larry
On 2/19/07, Jeff Butler [EMAIL PROTECTED] wrote:
iBATIS groupBy support does not support two independant lists. This would
be a very difficult problem to solve and would require us to deal with
object identity - which we don't deal with now.
So with
Please post an example of something that worked in 2.1.7 but fails in 2.3.0.
Jeff Butler
On 2/19/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Hi Jeff,
I'm very confused. Our application has many examples of independent
lists as in Claudio's example. This worked until we implemented
That's a good solution - then you could deal with object identity yourself.
Jeff Butler
On 2/19/07, Larry Meadors [EMAIL PROTECTED] wrote:
..or you could use a rowhandler.
Larry
On 2/19/07, Jeff Butler [EMAIL PROTECTED] wrote:
iBATIS groupBy support does not support two independant
com.ibatis.common.jdbc.exception.NestedSQLException:
--- The error occurred in Pratica.xml.
--- The error occurred while applying a parameter map.
--- Check the insertPraticaOracle-InlineParameterMap.
--- Check the parameter mapping for the 'descrizione' property.
--- Cause:
it seems that the descrizione field has an incorrect type i.e. your sql
is mapping the column descrizione to the wrong type.
I can guess that descrizione is a varchar2 column, is the corresponding
java property a String? is there any chance that you are mapping columns
and java properties in
I am using java String and oracle Varchar2
giuseppe
-Messaggio originale-
Da: Giovanni Cuccu - CUP2000 [mailto:[EMAIL PROTECTED]
Inviato: lunedì 19 febbraio 2007 17.31
A: user-java@ibatis.apache.org
Oggetto: Re: R: R: handling null values
it seems that the descrizione field has an
Yes, but usually I see that used with properties of the
Result class. How can I use that with the Result class
itself?
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of "Larry Meadors"
[EMAIL PROTECTED]Sent: Monday, February 19, 2007 5:10
AMTo:
Yes, but usually I see that used with properties of the
Result class. How can I use that with the Result class
itself?
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of "Larry Meadors"
[EMAIL PROTECTED]Sent: Monday, February 19, 2007 5:10
AMTo:
Hello,
Can someone differentiate for me the reasoning behind these two
functions in SqlMapDaoTemplate:
Object queryForObject(String id, Object parameters);
and
Object queryForObject(String id, Object parameters, Object result);
The docs appear very similar on them except that the first
I have a table which has all of the parent/child relationships in the same
table. I would like to avoid the N+1 selects with this construct, but it's
unclear from the documentation if this can be done.
Let's say I have the following relationships defined in the table:
Grand Parent
Parent 1
You'll need one query with 3 result maps. The result maps will be chained
together with collection properties using the resultMap attribute.
resultMap id=Child
...
resultMap id=Parent
result ... resultMap=Child/
...
resultMap id=GrandParent
result ... resultMap=Parent/
...
select ...
I guess I'll have to take a different approach. The depth isn't set to be a
defined level; so if I go more than two levels below the grandparent, it
won't work.
On 2/19/07, Clinton Begin [EMAIL PROTECTED] wrote:
You'll need one query with 3 result maps. The result maps will be chained
Oh...is it a self join?
Clinton
On 2/19/07, Brad Handy [EMAIL PROTECTED] wrote:
I guess I'll have to take a different approach. The depth isn't set to be
a defined level; so if I go more than two levels below the grandparent, it
won't work.
On 2/19/07, Clinton Begin [EMAIL PROTECTED] wrote:
Some DBs have support for selecting trees, like Oracle and Postgres' CONNECT_BY
functions. I don't have my O'Reilly SQL Cookbook handy, but it's got a chapter
on the different DBs (although it completely skips over the Postgres CONNECT_BY
function), if you want some pointers.
If your DB has
Hey Bradley!
So what's the database?
Larry
On 2/19/07, Brad Handy [EMAIL PROTECTED] wrote:
I guess I'll have to take a different approach. The depth isn't set to be a
defined level; so if I go more than two levels below the grandparent, it
won't work.
On 2/19/07, Clinton Begin [EMAIL
25 matches
Mail list logo