Results 1 to 3 of 3

Thread: Is there anyway I could disable SQLErrorCode translation?

  1. #1
    Join Date
    Oct 2004
    Location
    New York, NY
    Posts
    8

    Default Is there anyway I could disable SQLErrorCode translation?

    I am in an environment where XML parsing is screwed up. Is there anyway to disable the SQLErrorCode translation so I could at least use Spring JDBC support classes?

    I am doing a plugin for some 3rd party web app on WAS4.07 with UDB. If I don't have xml parser there, I got this:
    java.lang.NoClassDefFoundError: org/xml/sax/SAXException
    If I manually load them(xml-api.jar and xercesImpl.jar, then I got this:
    java.lang.ExceptionInInitializerError: java.lang.ClassCastException: org.apache.xerces.jaxp.DocumentBuilderFactoryImpl
    I also noticed that there are some SAX parser in the classpath of the web app, they somehow got screwed up. Besides, I have no control over this web app, I am just doing a plugin to go to UDB and get some data back.

    If I run my code in a seperate web app, I could use either Spring JDBC or Spring + iBATIS without any problem(WSAD5).

    Thanks,
    Rick

  2. #2
    Join Date
    Oct 2004
    Location
    New York, NY
    Posts
    8

    Default More exploring ...

    I went throught some of the source code to see whether I could get around the XML parsing problem. I am subclassing StoreProcedure, which has a JDBCTemplate that inherits from the class JdbcAccessor. If I manually set the exceptionTranslator field in JdbcAccessor with the class SQLStateSQLExceptionTranslator, which does not involve any XML, will JdbcAccessor's getExceptionTranslator() method return SQLStateSQLExceptionTranslator as expected?

    Thanks for any help.
    Rick

  3. #3
    Join Date
    Aug 2004
    Location
    Toronto, Canada
    Posts
    736

    Default

    Yes, it's quite valid to subclass jdbcTemplate to place around with the error code translator handling strategy...

Similar Threads

  1. Replies: 2
    Last Post: Aug 4th, 2006, 01:37 PM
  2. Disable Authentication
    By Luis Alejandro in forum Security
    Replies: 9
    Last Post: Sep 19th, 2005, 08:02 AM
  3. Replies: 2
    Last Post: Apr 27th, 2005, 02:18 AM
  4. Replies: 9
    Last Post: Mar 23rd, 2005, 08:49 AM
  5. Disable Buttons in a CommandGroup
    By besbello in forum Swing
    Replies: 2
    Last Post: Aug 31st, 2004, 08:06 PM

Posting Permissions

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