RE: need help - custom result set with no mapping

2006-03-29 Thread Mike Wilson
You don't want to know"Lingala, Sadasiva" [EMAIL PROTECTED] wrote: Thanks Larry.1. I still think there is a benefit using ibatis (if I can) in this caseas I can use all the parameter mapping and externalizing the SQL etc..2. Solution for not just accessing DAOs but also for developers

Re: Pattern for multiple database

2006-03-29 Thread j-lists
A clever use of sql id=foo/sql and include refid=foo/ where the sql is in the ${dialect} file will give some pretty reasonable flexability without the need to exploit any bugs. I have recently posted a JIRA feature request precisely to help address key generation aspect of the cross-DB

Re: Views and dynamic queries

2006-03-29 Thread Larry Meadors
Does the view name have a # or $ character in it? Larry On 3/29/06, Chema [EMAIL PROTECTED] wrote: Hello: I've got this query in sqlmap config file select remapResults =true id=getValue resultClass=java.lang.Object parameterClass=QueryClass SELECT $c$ FROM $table$

Re: Views and dynamic queries

2006-03-29 Thread Diran Ayandele
This is probably a syntax error in your sql. That error message from oracle often indicates a comma in the wrong place or parenthesis that is unmatched. I would use your logs to see exactly what sql you're sending to your database. Or else run your statements using sqlplus to see a nice

Table alias in results map.

2006-03-29 Thread Daniel Pitts
I want to perform a query like: select id=getData resultClass=map parameterClass=string Select * FROM data AS `root:data` JOIN other AS `root:other` JOIN something as `root:other:something` WHERE $where$ /select The tables data, other, and something may or may not have similarly named columns.

Re: Table alias in results map.

2006-03-29 Thread Jeff Butler
Short answer - no. Only the column name is returned in the result set. This is JDBC, not just iBATIS. Run the query in something like the Squirrel SQL client to verify. A better solution would be to use a real domain object instead of a map, and use iBATIS' group by and descriminator support.

A couple of questions

2006-03-29 Thread Tony Qian
All, Got two questions on iBATIS DAO. 1) I have two tables. Those two tables happen to have a column with same name. I try to join those two table first and then use groupBy to construct two lists, one for each table. The problem is that I cannot use table qualifier to specify the data from

Re: A couple of questions

2006-03-29 Thread Eric T. Blue
Tony, Try aliasing the duplicate columns. For example: Select a.column1 as a_column1, b.column1 as b_column1 from table1 a, table2 b where b.some_id = a.idOn 3/29/06, Tony Qian [EMAIL PROTECTED] wrote: All, Got two questions on iBATIS DAO. 1) I have two tables. Those two tables happen

Running iBATIS app on JBoss

2006-03-29 Thread Mike Wilson
Greetings,I am trying to deploy an iBATIS app on JBoss 4.0.2 which has been running fine on Tomcat 4.1, but am getting this error:org.jboss.deployment.DeploymentException: Error during deploy; - nested throwable: (javax.naming.NamingException: resource-ref: jdbc/testapp1 has no valid JNDI

Re: customize XML output

2006-03-29 Thread Clinton Begin
Nope. And I suggest not using the XML output anyway. Instead, consider mapping it to a real domain model, then use something like XStream to serialize it to XML.Cheers,Clinton On 3/26/06, sadasiva lingala [EMAIL PROTECTED] wrote: Hi Is there a way to customize xml output by extending the ibatis

Re: reusing resultMaps without extending them.

2006-03-29 Thread Clinton Begin
Hmm...unfortunately at this time your two choices are to extend it or duplicate it. As you've discovered, the resultMap attribute of the result element is strictly for collections only. Cheers,Clinton On 3/27/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I can't seem to find any documentation on

RE: How to convert BLOB/CLOB to String.

2006-03-29 Thread Niels Beekman
You should really take a look at the docs, its all there Niels From: Zsolt [mailto:[EMAIL PROTECTED] Sent: donderdag 30 maart 2006 8:14 To: user-java@ibatis.apache.org Subject: RE: How to convert BLOB/CLOB to String. I dont want to convert all BLOBs to String only for