Maybe Bruce Snyder, Mickael Guessant or Rhett Sutphin can help you.
Ralf
----- Original Message -----
From: "Hiran Chaudhuri" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, March 05, 2003 6:01 PM
Subject: Re: [castor-dev] unclean code in Castor JDO Engine? (was: Problem running
sample)
> Hi, Ralf.
>
> Thank you for your answer.
>
> Tamino is a Software AG product, and Software AG is my employer. So I know
> where to get support. ;-)
> My only problem is that I have been working with the Tamino as native XML
> database for years, and my SQL knowledge has become a bit dusty. That's why
> I found out such "basic" things.....
>
> However, I believe that Castor should treat data with the type that the
> database sais it is, or at least listen to the mapping file. Both does not
> seem to be the case here. Who can comment on that?
>
> Hiran
>
> ----- Original Message -----
> From: "Ralf Joachim" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, March 05, 2003 5:32 PM
> Subject: Re: [castor-dev] unclean code in Castor JDO Engine? (was: Problem
> running sample)
>
>
> > Hi Hiran,
> >
> > I also recognized conversion from integer to big decimal at oracle. In my
> case the reason is the
> > type handling of oracle.
> >
> > I create a table with SQL:
> >
> > CREATE TABLE TEST_01 (ID INTEGER)
> >
> > When I check the datatype oracle uses and delivers when I request the SQL
> type with JDBC I get:
> >
> > NUMBER(38)
> >
> > Castor handles this by automatic converting java.lang.Integer to
> javax.sql.BigDecimal.
> >
> > May there be something similar causing your problem?
> >
> > As I have no experience with Tamino I do not know how Tamino handles
> references to other records
> > or objects. It may be possible that Tamino has its own object relational
> mapping and do not expect
> > the primary key of the referenced record but a reference to the object. In
> this case you will not need
> > and can not use Castor together with Tamino.
> >
> > Maybe there is someone else out there who knows Tamino better than I do.
> >
> > Ralf
> >
> >
> > ----- Original Message -----
> > From: "Hiran Chaudhuri" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, March 05, 2003 3:29 PM
> > Subject: [castor-dev] unclean code in Castor JDO Engine? (was: Problem
> running sample)
> >
> >
> > > Hi there.
> > >
> > > Having investigated quite some time into this issue I come up with this
> > > result:
> > >
> > > The table I have defined contains an integer row. Via JDBC this row is
> > > recognized as java.sql.Types.INTEGER. In the mapping file, both the java
> > > property and the sql row are typed as "integer". Castor tries to set a
> value
> > > with the method
> > >
> > > PreparedStatement.setObject(4, new java.math.BigDecimal("3"),
> > > java.sql.Types.NUMERIC);
> > >
> > > which the JDBC driver rejects. I seem to be unable to convince Castor to
> use
> > > java.sql.Types.INTEGER for this operation. What can be done (beyond
> changing
> > > Castor or the JDBC driver? Are there some tricks for the mapping file?
> What
> > > is the database type in database.xml set for? Can I use that to adapt
> Castor
> > > for Tamino SQL?
> > >
> > > Hiran
> > >
> > >
> > > ----- Original Message -----
> > > From: "Hiran Chaudhuri" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Tuesday, March 04, 2003 9:02 AM
> > > Subject: [castor-dev] Problem running sample
> > >
> > >
> > > > Hi there.
> > > >
> > > > Can someone give me a hint what's wrong running the castor sample?
> > > > - In database.xml I entered driver and connection information for my
> > > Tamino
> > > > SQL Engine.
> > > > - In create.sql I adapted the SQL statements so my database will
> create
> > > the
> > > > tables the way castor expects it.
> > > > - In mapping.xml I actually tried not to change anything, but....
> > > >
> > > > As Tamino SQL does not know about a numeric data type, I changed that
> to
> > > > float/decimal/whatever. From JDBC the data type is mentioned as
> DOUBLE.
> > > > However I keep getting the listed error message, and suspect that it
> > > occurs
> > > > with the price field. If it is the group_id, what can I do to overcome
> > > that
> > > > error?
> > > >
> > > > Hiran
> > > >
> > > > [test] Creating new product: <id: 4 name: product4>
> > > > [test] Castor: Creating myapp.Product (4)
> > > > [test] Error creating myapp.Product, SQL : INSERT INTO "prod"
> > > > ("id","name","price","group_id") VALUES (?,?,?,?)
> > > > [test] org.exolab.castor.jdo.PersistenceException: Nested error:
> > > > java.sql.SQLException: setDouble() is wrong Method to set
> inputparameter 4
> > > > [test] java.sql.SQLException: setDouble() is wrong Method to set
> > > > inputparameter 4
> > > > [test] at
> > > > de.sag.jdbc.tsql.server.AInputServer.checkType(AInputServer.java:930)
> > > > [test] at
> > > > de.sag.jdbc.tsql.server.AInputServer.setDouble(AInputServer.java:345)
> > > > [test] at
> > > >
> de.sag.jdbc.tsql.server.AInputServer.setBigDecimal(AInputServer.java:351)
> > > > [test] at
> > > > de.sag.jdbc.tsql.server.AInputServer.setObject(AInputServer.java:723)
> > > > [test] at
> > > >
> de.sag.jdbc.tsql.APreparedStatement.setObject(APreparedStatement.java:665)
> > > > [test] at
> > > >
> de.sag.jdbc.tsql.APreparedStatement.setObject(APreparedStatement.java:674)
> > > > [test] at
> > > > org.exolab.castor.jdo.engine.SQLTypes.setObject(SQLTypes.java:420)
> > > > [test] at
> > > org.exolab.castor.jdo.engine.SQLEngine.create(SQLEngine.java:598)
> > > > [test] at
> > > > org.exolab.castor.persist.ClassMolder.create(ClassMolder.java:903)
> > > > [test] at
> > > org.exolab.castor.persist.LockEngine.create(LockEngine.java:458)
> > > > [test] at
> > > >
> > >
> org.exolab.castor.persist.TransactionContext.create(TransactionContext.java:
> > > > 883)
> > > > [test] at
> > > >
> org.exolab.castor.jdo.engine.DatabaseImpl.create(DatabaseImpl.java:366)
> > > > [test] at castorjdo.Test.run(Test.java:222)
> > > > [test] at castorjdo.Test.main(Test.java:63)
> > > >
> > >
> > >
> >
> >
>
>