Re: Setup hsqldb tables in memory?

From: Cris Daniluk (cris.danilu..mail.com)
Date: Fri Nov 03 2006 - 09:13:59 EST

  • Next message: Christian Mittendorf: "Re: Setup hsqldb tables in memory?"

    Looks ilke the DOUBLE(22) is the problem.. HSQLDB doesn't support
    precision on a double. Can you include the DbEntity in the DataMap?
    the ObjEntity isn't very helpful.

    Cris

    On 11/3/06, Christian Mittendorf <christian.mittendor..reenet.de> wrote:
    >
    > Am 03.11.2006 um 00:01 schrieb Christian Mittendorf:
    >
    > > Thanks to all of your for hints!
    >
    > Ok, I'm now quite close to what I would like to accomplish. Except
    > for one Exception...
    >
    > 09:43:01,565 INFO [QueryLogger] *** error.
    > java.sql.SQLException: Unexpected token in statement [CREATE CACHED
    > TABLE invoices (anum VARCHAR(45) NULL, belegNummer BIGINT NOT NULL,
    > cid BIGINT NOT NULL, id BIGINT NOT NULL, mahnStufe INTEGER NOT NULL,
    > opNummer VARCHAR(45) NOT NULL, rechnungsBetrag DOUBLE(22]
    > at org.hsqldb.jdbc.Util.sqlException(Unknown Source)
    > at org.hsqldb.jdbc.jdbcStatement.fetchResult(Unknown Source)
    > at org.hsqldb.jdbc.jdbcStatement.execute(Unknown Source)
    > at org.objectstyle.cayenne.access.DbGenerator.safeExecute
    > (DbGenerator.java:399)
    > at org.objectstyle.cayenne.access.DbGenerator.runGenerator
    > (DbGenerator.java:339)
    > at de.freenet.cayenne.junit.DatabaseTestCase.setUpDataNodes
    > (DatabaseTestCase.java:66)
    > at de.freenet.cayenne.junit.DatabaseTestCase.setUp
    > (DatabaseTestCase.java:38)
    > at junit.framework.TestCase.runBare(TestCase.java:125)
    > at junit.framework.TestResult$1.protect(TestResult.java:106)
    > at junit.framework.TestResult.runProtected(TestResult.java:124)
    > at junit.framework.TestResult.run(TestResult.java:109)
    > at junit.framework.TestCase.run(TestCase.java:118)
    > at junit.framework.TestSuite.runTest(TestSuite.java:208)
    > at junit.framework.TestSuite.run(TestSuite.java:203)
    > at
    > org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run
    > (JUnit3TestReference.java:128)
    > at org.eclipse.jdt.internal.junit.runner.TestExecution.run
    > (TestExecution.java:38)
    > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests
    > (RemoteTestRunner.java:460)
    > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests
    > (RemoteTestRunner.java:673)
    > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run
    > (RemoteTestRunner.java:386)
    > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main
    > (RemoteTestRunner.java:196)
    >
    > I've validated the cayenne project with the modeler and everything
    > seems to be fine. In the xml the table looks like this:
    >
    > <obj-entity name="Invoices"
    > className="de.freenet.cayenne.bonitaet.Invoices"
    > dbEntityName="invoices">
    > <obj-attribute name="anum" type="java.lang.String" db-attribute-
    > path="anum"/>
    > <obj-attribute name="belegNummer" type="java.lang.Long" db-attribute-
    > path="belegNummer"/>
    > <obj-attribute name="cid" type="java.lang.Long" db-attribute-
    > path="cid"/>
    > <obj-attribute name="mahnStufe" type="java.lang.Integer" db-
    > attribute-path="mahnStufe"/>
    > <obj-attribute name="opNummer" type="java.lang.String" db-attribute-
    > path="opNummer"/>
    > <obj-attribute name="rechnungsBetrag" type="java.lang.Double" db-
    > attribute-path="rechnungsBetrag"/>
    > <obj-attribute name="rechnungsDatum" type="java.util.Date" db-
    > attribute-path="rechnungsDatum"/>
    > </obj-entity>
    >
    > Any idea anybody?
    >
    > Christian
    >
    >



    This archive was generated by hypermail 2.0.0 : Fri Nov 03 2006 - 09:14:29 EST