Results 1 to 10 of 10
  1. #1
    Join Date
    Jan 2005
    Posts
    11

    Question Unanswered: DB2 SQL error: SQLCODE: -104, SQLSTATE: 42601, SQLERRMC:

    DB2 SQL error: SQLCODE: -104, SQLSTATE: 42601, SQLERRMC:

    Iam getting this errror while using jcc connectivity.All my sql statements are simple select statements.Can you please tell what i shd do to solve this error?

    Thanks in Advance
    San

  2. #2
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    What does the Messages and Codes manual say about this? You can download the manuals from the IBM site (see Useful DB2 Stuff thread).
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  3. #3
    Join Date
    Jan 2005
    Posts
    11
    Thanks for your reply.
    I checked the sql error in manuals but i didnot understand it.

    I am getting the following error on this sql statement:
    Select POLNUM,ACTION,MEMONUM FROM POLMEMO WHERE POLNUM='12239598 'AND MEMONUM = (SELECT MAX(MEMONUM) FROM POLMEMO WHERE POLNUM='12239598 ');

    Exception in ROLE OR POLMASTN dbconnB2 SQL error: SQLCODE: -104, SQLSTATE: 42601, SQLERRMC: ;;POLNUM='12239598 ');END-OF-STATEMENT

    Any suggestions would be appreciated.

  4. #4
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    I don't know anything about jcc, but it looks like there may be a problem with the statement termination character.
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  5. #5
    Join Date
    Jan 2005
    Posts
    11
    Hi,
    Thanks, that error was indeed due to the last character.It was running fine using jdbc. But with jcc it was showing error.

    I got another error:
    Exception in dbconnB2 SQL error: SQLCODE: -805, SQLSTATE: 51002, SQLERRMC: NULLID.SYSLH203 0X5359534C564C3031

    Any suggestions?

  6. #6
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650
    IIRC, this problem was fixed in FP3 .. What fixpak are you on ??
    Visit the new-look IDUG Website , register to gain access to the excellent content.

  7. #7
    Join Date
    Jan 2005
    Posts
    11
    Can you tell me how do i find out what fixpack iam on?

  8. #8
    Join Date
    May 2003
    Location
    USA
    Posts
    5,737
    db2level (from the command line).
    M. A. Feldman
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows
    IBM Certified DBA on DB2 for z/OS and OS/390

  9. #9
    Join Date
    Jan 2005
    Posts
    11
    Thanks , fixpack iam on is DB2 SDK 8.1.5

  10. #10
    Join Date
    Jan 2005
    Posts
    11
    Sorry the fixpack iam on is 5.

    DB21085I Instance "DB2" uses "32" bits and DB2 code release "SQL08015" with level identifier "02060106".
    Informational tokens are "DB2 v8.1.5.449", "s040212", "WR21334", and FixPak
    "5".

Posting Permissions

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