Results 1 to 3 of 3

Thread: DB2 jdbc error

  1. #1
    Join Date
    Aug 2004
    Location
    India
    Posts
    13

    Unanswered: DB2 jdbc error

    I have a db2 table T_CNTRT_NOTES

    When I run the following query through my java application :

    SELECT TRANSACTION_NUMBER FROM DB2ADMIN.T_CNTRT_NOTES WHERE CONTRACT_NOTE_NUMBER = '111111'

    I get the following error

    COM.ibm.db2.jdbc.DB2Exception: [IBM][JDBC Driver] CLI0611E Invalid column name. SQLSTATE=S0022

    though the column already Exists

    When I run the same query from db2 command line it works fine

    I am using IBM DB2 version 8.1 on AIX 4.3

    Any help would be greatly appreciated

    Thanks

    Falcon

  2. #2
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    Are you connected to the same database in both cases ...

    In your application use the metadata apis and get information on the table columns and confirm the column exists in the database you connect to

    Cheers
    Sathyaram
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  3. #3
    Join Date
    Aug 2004
    Location
    India
    Posts
    13
    Hi Sathyaram

    I am connected to the same database and the column exists in the database

    The query runs fine on DB2 command line but it fails in java application

    Regards

    Falcon

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •