Uploaded image for project: 'Spring Framework'
  1. Spring Framework
  2. SPR-9853

Add JDBC exception translation support for Oracle error code ORA-06550

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1.1
    • Fix Version/s: 3.1.3, 3.2 RC1
    • Component/s: None
    • Labels:
      None
    • Last commented by a User:
      true

      Description

      When I use SimpleJdbcCall class to call DB function (executeFunction()) which doesn't exists (e.g. provde invalid schema name), then I got following message:

      CallableStatementCallback; uncategorized SQLException for SQL [{? = call My_Procedure_Name SQL state [99999]; error code [17041]; Missing IN or OUT parameter at index:: 1
      

      This message suggest that something is wrong with parameters which is not the case.
      When I call a missing DB procedure (execute()) got following message:

      CallableStatementCallback; bad SQL grammar [{call My_procedure_name}]; nested exception is java.sql.SQLException: ORA-06550: line 1, column 7:
      PLS-00201: identifier 'My_procedure_name' must be declared
      

      I test it on Oracle database, so you see here Oracle specific error code (ORA-06550), but this is only an example. Second message is OK - it gives information what's really wrong.

        Attachments

          Activity

            People

            Assignee:
            pwebb Phil Webb
            Reporter:
            phil Phil Barnes
            Last updater:
            Spring Issues Spring Issues
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Days since last comment:
              3 years, 29 weeks, 6 days ago