2 Replies Latest reply on Nov 6, 2002 10:26 AM by mimi

    Invalid Column Name

    Sean Cohan Newbie

      We're using Jboss 3.0.3 (on Linux) and Oracle 8i (on Win 2K) trying to set up XA connections. In my app, I am trying to executa a sql insert statement. When executed, a SQLException is raised. In the JBoss console window I see the following:

      [STDOUT] problem statement -> insert into access_log (accs_log_id, log_ts, code, ip_address, ecass_user_id) values (security_seq.nextval, TO_DATE('2002-10-28 15:38:12','YYYY-MM-DD HH24:MI:SS'), 'User does not exist: scohan / scohan', '127.0.0.1', 'scohan') -OR- [STDOUT] java.sql.SQLException: ORA-00904: invalid column name

      The column names are correct however. I can copy and paste the exact insert statement into sqlplus and it executes fine.

      I'm wondering whether there is a problem with out JBoss/Oracle Driver/XA configuration.

      Any ideas on what to try or do next?

      Thanks.

      P.S. Eventually we will be going to Oracel 9i on Linux.

        • 1. Re: Invalid Column Name
          Sean Cohan Newbie

          To provide more info on what we have, here's my mbean from oracle_xa_service.xml (should we just wait till we go to Oracle 9i or should this work with 8i?):

          <!-- ===================================================================== -->
          <!-- -->
          <!-- Security DataSource -->
          <!-- -->
          <!-- ===================================================================== -->

          <!--make the rar deploy! hack till better deployment-->
          jboss.jca:service=RARDeployer


          <depends optional-attribute-name="ManagedConnectionFactoryName">
          <!--embedded mbean-->

          <!--hack-->
          <depends optional-attribute-name="OldRarDeployment">jboss.jca:service=RARDeployment,name=Minerva JDBC XATransaction ResourceAdapter

          <!--real attributes-->


          <config-property name="XADataSourceProperties"
          type="java.lang.String">URL=jdbc:oracle:thin:@bxatest2:1521:SECURITY</config-property>
          <config-property name="XADataSourceClass"
          type="java.lang.String">oracle.jdbc.xa.client.OracleXADataSource</config-property>
          <!--set these only if you want only default logins, not through JAAS -->
          <config-property name="UserName"
          type="java.lang.String"></config-property>
          <config-property name="Password"
          type="java.lang.String"></config-property>
          <!--
          Do not try to set transaction isolation level here or you'll get
          java.sql.SQLException: ORA-01453: SET TRANSACTION must be first statement of transaction
          Read committed is a default isolation level for Oracle, so there
          is not real need to set it here. I'll take a look into it later ...maybe.
          <config-property name="TransactionIsolation"
          type="java.lang.String">TRANSACTION_READ_COMMITTED</config-property>
          -->


          XAOracleSecurityDS



          <depends optional-attribute-name="ManagedConnectionPool">
          <!--embedded mbean-->


          0
          50
          5000
          15
          <!--criteria indicates if Subject (from security domain) or app supplied
          parameters (such as from getConnection(user, pw)) are used to distinguish
          connections in the pool. Choices are
          ByContainerAndApplication (use both),
          ByContainer (use Subject),
          ByApplication (use app supplied params only),
          ByNothing (all connections are equivalent, usually if adapter supports
          reauthentication)-->
          ByContainer


          <depends optional-attribute-name="CachedConnectionManager">jboss.jca:service=CachedConnectionManager

          • 2. Re: Invalid Column Name
            mimi Newbie

            Hi,

            I am having the same problem using Mysql.

            I copied the Template TestEntityBean and refered it to a Table in MySQl. When I do a findAll() I get a Invalid Column name, however I execute the same command in mysql it works fine.

            I would be interested if you have found out what is going wrong.

            Thanks

            Jag