0 Replies Latest reply on Oct 28, 2004 3:36 PM by jai hilal

    informix-jdbc2-service.xml

    jai hilal Newbie


      Hi friends,

      I am using jboss 3.2.3 and I want to store the jms messages in
      Informix SE database.I created the informix-ds.xml and informix-jdbc2-service.xml files.The database does not support BLOB.So I used a CHAR field to store message.But when I try to send a text message to my local Queue it gives error.Is there any way to store the jms messages in a CHAR field?

      please help

      The informix-jdbc2-service.xml is


      <depends optional-attribute-name="ConnectionManager">jboss.jca:service=LocalTxCM,name=InformixDS

      INSERT_TX = INSERT INTO JMS_TRANSACTIONS (TXID) values(?)
      INSERT_MESSAGE = INSERT INTO JMS_MESSAGES (MESSAGEID, DESTINATION, MESSAGEBLOB, TXID, TXOP) VALUES(?,?,?,?,?)
      SELECT_ALL_UNCOMMITED_TXS = SELECT TXID FROM JMS_TRANSACTIONS
      SELECT_MAX_TX = SELECT MAX(TXID) FROM JMS_MESSAGES
      SELECT_MESSAGES_IN_DEST = SELECT MESSAGEID, MESSAGEBLOB FROM JMS_MESSAGES WHERE DESTINATION=?
      SELECT_MESSAGE = SELECT MESSAGEID, MESSAGEBLOB FROM JMS_MESSAGES WHERE MESSAGEID=? AND DESTINATION=?
      MARK_MESSAGE = UPDATE JMS_MESSAGES SET TXID=?, TXOP=? WHERE MESSAGEID=? AND DESTINATION=?
      UPDATE_MESSAGE = UPDATE JMS_MESSAGES SET MESSAGEBLOB=? WHERE MESSAGEID=? AND DESTINATION=?
      UPDATE_MARKED_MESSAGES = UPDATE JMS_MESSAGES SET TXID=?, TXOP=? WHERE TXOP=?
      UPDATE_MARKED_MESSAGES_WITH_TX = UPDATE JMS_MESSAGES SET TXID=?, TXOP=? WHERE TXOP=? AND TXID=?
      UPDATE_MESSAGE = UPDATE JMS_MESSAGES SET MESSAGEBLOB=? WHERE MESSAGEID=? AND DESTINATION=?
      UPDATE_MARKED_MESSAGES = UPDATE JMS_MESSAGES SET TXID=?, TXOP=? WHERE TXOP=?
      UPDATE_MARKED_MESSAGES_WITH_TX = UPDATE JMS_MESSAGES SET TXID=?, TXOP=? WHERE TXOP=? AND TXID=?
      DELETE_MARKED_MESSAGES_WITH_TX = DELETE FROM JMS_MESSAGES WHERE TXID IN (SELECT TXID FROM JMS_TRANSACTIONS) AND TXOP=?
      DELETE_TX = DELETE FROM JMS_TRANSACTIONS WHERE TXID = ?
      DELETE_MARKED_MESSAGES = DELETE FROM JMS_MESSAGES WHERE TXID=? AND TXOP=?
      DELETE_MESSAGE = DELETE FROM JMS_MESSAGES WHERE MESSAGEID=? AND DESTINATION=?
      CREATE_MESSAGE_TABLE = CREATE TABLE JMS_MESSAGES (MESSAGEID INTEGER NOT NULL, DESTINATION VARCHAR(150) NOT NULL, TXID INTEGER, TXOP CHAR(1), MESSAGEBLOB CHAR(32000), PRIMARY KEY (MESSAGEID, DESTINATION))
      CREATE_TX_TABLE = CREATE TABLE JMS_TRANSACTIONS (TXID INTEGER)
      CREATE_TABLES_ON_STARTUP = TRUE



      ERROR

      org.jboss.mq.SpyTransactionRolledBackException: Transaction was rolled back.; - nested throwable: (org.jboss.mq.SpyJMSException: Could not store message: 1 msg=0 hard NOT_STORED PERSISTENT queue=QUEUE.A priority=4 hashCode=25944206; - nested throwable: (java.sql.SQLException: System or internal error java.lang.NoSuchMethodException: com.informix.jdbc.IfxChar.fromnull(org.jboss.mq.SpyStreamMessage)))
      at org.jboss.mq.server.JMSDestinationManager.transact(JMSDestinationManager.java:452)
      at org.jboss.mq.server.JMSServerInterceptorSupport.transact(JMSServerInterceptorSupport.java:186)
      at org.jboss.mq.server.TracingInterceptor.transact(TracingInterceptor.java:438)
      at org.jboss.mq.server.JMSServerInvoker.transact(JMSServerInvoker.java:186)
      at org.jboss.mq.il.uil2.ServerSocketManagerHandler.handleMsg(ServerSocketManagerHandler.java:166)
      at org.jboss.mq.il.uil2.SocketManager$ReadTask.handleMsg(SocketManager.java:355)
      at org.jboss.mq.il.uil2.msgs.BaseMsg.run(BaseMsg.java:377)
      at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:732)
      at java.lang.Thread.run(Thread.java:534)
      Caused by: org.jboss.mq.SpyJMSException: Could not store message: 1 msg=0 hard NOT_STORED PERSISTENT queue=QUEUE.A priority=4 hashCode=25944206; - nested throwable: (java.sql.SQLException: System or internal error java.lang.NoSuchMethodException: com.informix.jdbc.IfxChar.fromnull(org.jboss.mq.SpyStreamMessage))
      at org.jboss.mq.pm.jdbc2.PersistenceManager.add(PersistenceManager.java:745)
      at org.jboss.mq.server.PersistentQueue.addMessage(PersistentQueue.java:44)
      at org.jboss.mq.server.JMSQueue.addMessage(JMSQueue.java:145)
      at org.jboss.mq.server.JMSDestinationManager.addMessage(JMSDestinationManager.java:407)
      at org.jboss.mq.server.JMSDestinationManager.transact(JMSDestinationManager.java:433)
      ... 8 more
      Caused by: java.sql.SQLException: System or internal error java.lang.NoSuchMethodException: com.informix.jdbc.IfxChar.fromnull(org.jboss.mq.SpyStreamMessage)
      at com.informix.util.IfxErrMsg.getSQLException(IfxErrMsg.java:430)
      at com.informix.jdbc.IfxObject.findMethod(IfxObject.java:179)
      at com.informix.jdbc.IfxObject.fromObject(IfxObject.java:206)
      at com.informix.jdbc.IfxValue.makeInstance(IfxValue.java:518)
      at com.informix.jdbc.IfxValue.makeInstance(IfxValue.java:432)
      at com.informix.jdbc.IfxPreparedStatement.setObject(IfxPreparedStatement.java:2224)
      at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.setObject(WrappedPreparedStatement.java:641)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.setBlob(PersistenceManager.java:838)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.add(PersistenceManager.java:775)
      at org.jboss.mq.pm.jdbc2.PersistenceManager.add(PersistenceManager.java:730)
      ... 12 more