Uploaded image for project: 'Beehive'
  1. Beehive
  2. BEEHIVE-868

Calling stored proc with uppercase 'CALL', and providing SQLParameter arguments, results in a compiler error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 1.0.1
    • System Controls
    • None

    Description

      When trying to call SP's via the JdbcControl, and sending SQLParameters as arguments, a compile time error will be thrown if the 'CALL' part of the statement is in uppercase. The statement works fine if lowercase 'call' is used instead. It could be that this is a side-effect of the special processing of the statement that is done because of the presence of the SQLParameter argument.

      Error:
      org.apache.beehive.controls.api.ControlException: Error parsing SQL statment.Encountered " " at line 1, column 6.
      [apt] Was expecting one of:
      [apt] "}" ...
      [apt] "|" ...
      [apt] [Encountered " " at line 1, column 6.
      [apt] Was expecting one of:
      [apt] "}" ...
      [apt] "|" ...
      [apt] ]
      [apt] public void callSP_name_city(SQLParameter[] sqlParameters) throws SQLException;

      Workaround:
      Only use lowercase 'call' when accessing SP's with SQLParameters.

      Repro:
      Call a SP, providing a SQLParameter as an argument, and use an uppercase 'CALL' as part of the statement.

      Attachments

        1. BEEHIVE-868.diff
          7 kB
          Chad Schoettger

        Activity

          People

            grunlowen matt c
            chad_s Chad Schoettger
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: