1 Reply Latest reply on Oct 3, 2002 4:48 PM by torben morello

    Cloudscape Problem with JBoss 3

    torben morello Newbie

      I ported my CMP2.0-Application from Sun's RI to JBoss 3. This worked fine, but instead of Cloudscape JBoss used the DefaultDS, Hypersonic DB. Then I started to change the DefaultDS to Cloudscape by doing the folling:

      - I started cloudscape on port 1098 (to avoid the conflict with JNS)

      - I deleted hsqldb-service.xml in the deploy dir and put my cloudscape-service.xml there. this file is similar to the hsqldb-file, I left the JndiName as DefaultDS, I just put the right ConnectionURL, DriverClass, UserName and Password there and deleted the jboss.service lines, since I start the cloudscape by myself (JBoss warns me now on startup that there's no service defined for jboss.jca:service=LocalTxDS,name=cloudscapeDS, but it shouldn't matter, right?)

      - I changed the <type-mapping> in standardjaws.xml and standardjbosscmp-jdbc.xml to Cloudscape

      - I put the cloudscape libs in the \lib folder (jboss echos the successful loading on startup)

      Starting JBoss seems to work fine, but problems come up when I deploy my application:

      20:08:33,027 INFO [ActivityDN] Created table 'ACTIVITYDN' successfully.
      20:08:33,107 ERROR [EjbModule] Starting failed
      org.jboss.deployment.DeploymentException: Error while creating table; - nested throwable: (SQL Exception: Syntax error: Encountered "date" at line 1, column 56.) at org.jboss.ejb.plugins.cmp.jdbc.JDBCStartCommand.createTable(JDBCStartCommand.java:190)

      jboss is able to create some tables (there are some more successful above), so datasource seems to be ok, but maybe it is wrong configuered... but where can I find what SQL for creating the table was used? (wo I can use error position for debugging) Or have I forgotten some important step in changing the DefaultDS? Has anybody had a similar problem?

      Help appreciated - torben

        • 1. Re: Cloudscape Problem with JBoss 3
          torben morello Newbie

          ok, i got the problem.... it wasn't the data source configuration, that one worked already fine....
          but my jdbc-tracer tool unveiled the problem:
          one of my entity bean had a CMP Field date, and RI creates a table as follows:

          CREATE TABLE (..., "date" DATE, ...)

          but JBoss creates tables slightly different:

          CREATE TABLE (..., date DATE, ...)

          HyperSonicDB doesn't care about a column name equaling a data type, but cloudscape *DOES*.

          So I changed the name of the CMP Field and it works fine now. But is there a way to make JBoss use the quotation marks too?

          greets - torben