Derby
  1. Derby
  2. DERBY-493

SQLPROCEDURECOLS will fail with "schema not found" error if it is called when the current schema doesn't exist.

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 10.1.1.0, 10.2.1.6
    • Fix Version/s: None
    • Component/s: JDBC
    • Urgency:
      Normal
    • Issue & fix info:
      High Value Fix

      Description

      The SQLPROCEDURECOLS procedure that Derby defines internally to handle the DatabaseMetaData.getProcedureColumns() call (in JDBC) and the SQLProcedureColumns() call (in ODBC) will fail with "schema not found" error if it is called when "current schema" doesn't exist. This is a problem with Derby embedded, and thus can be seen from embedded mode, server mode (JDBC), and ODBC.

      None of the other metadata procedures have this problem; only SQLPROCEDURECOLS.

        Activity

        A B created issue -
        A B made changes -
        Field Original Value New Value
        Description The SQLPROCEDURECOLS procedure that Derby defines internally to handle the DatabaseMetaData.getProcedureColumns() call (in JDBC) and the SQLProcedureColumns() call (in ODBC) will fail with "schema not found" error if it is called when "current schema" doesn't exist. This is a problem with Derby embedded, and thus can be seen from embedded mode, server mode (JDBC), and ODBC/CLI.

        None of the other metadata procedures have this problem; only SQLPROCEDURECOLS.
        The SQLPROCEDURECOLS procedure that Derby defines internally to handle the DatabaseMetaData.getProcedureColumns() call (in JDBC) and the SQLProcedureColumns() call (in ODBC) will fail with "schema not found" error if it is called when "current schema" doesn't exist. This is a problem with Derby embedded, and thus can be seen from embedded mode, server mode (JDBC), and ODBC.

        None of the other metadata procedures have this problem; only SQLPROCEDURECOLS.
        Kathey Marsden made changes -
        Derby Categories [High Value Fix]
        Dag H. Wanvik made changes -
        Issue & fix info [High Value Fix]
        Hide
        Mike Matrigali added a comment -

        Triaged July 10, 2009: assigned normal urgency.

        Show
        Mike Matrigali added a comment - Triaged July 10, 2009: assigned normal urgency.
        Mike Matrigali made changes -
        Urgency Normal
        Kathey Marsden made changes -
        Labels derby_triage10_5_2
        Hide
        Knut Anders Hatlen added a comment -

        I tried to reproduce this problem by executing the following code snippet:

        Connection c = DriverManager.getConnection("jdbc:derby:db;user=nosuchschema;create=true");
        ResultSet rs = c.getMetaData().getProcedureColumns(null, "%", "%", "%");
        while (rs.next());
        rs.close();

        It fails with "ERROR 42Y07: Schema 'NOSUCHSCHEMA' does not exist" on Derby 10.1 (tested with 10.1.1.0, 10.1.2.1 and 10.1.3.1). However it does not reproduce on 10.2.1.6 and higher, so I'm assuming the problem that's described here has been fixed.

        Resolving the issue.

        Show
        Knut Anders Hatlen added a comment - I tried to reproduce this problem by executing the following code snippet: Connection c = DriverManager.getConnection("jdbc:derby:db;user=nosuchschema;create=true"); ResultSet rs = c.getMetaData().getProcedureColumns(null, "%", "%", "%"); while (rs.next()); rs.close(); It fails with "ERROR 42Y07: Schema 'NOSUCHSCHEMA' does not exist" on Derby 10.1 (tested with 10.1.1.0, 10.1.2.1 and 10.1.3.1). However it does not reproduce on 10.2.1.6 and higher, so I'm assuming the problem that's described here has been fixed. Resolving the issue.
        Knut Anders Hatlen made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Cannot Reproduce [ 5 ]
        Gavin made changes -
        Workflow jira [ 12323056 ] Default workflow, editable Closed status [ 12802105 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            A B
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development