0 Replies Latest reply: Aug 19, 2010 11:37 AM by user11032875 RSS

    Exeption in Oracle iStore JSP

    user11032875
      Hello,

      I am working on 11i and having issue with exception handling in iStore JSP. As we know iStore JSPs are compiled to .java which is then converted to .class file.

      During this I can use 'try/catch' to handle run-time error but not compile-time error.

      Let me give an example...

      Run-time Excpetion: xx_ibeCCtdMenu.jsp
      try
      {
      ...
      callablestatement.setBigDecimal(1, new BigDecimal(s));
      ...
      }
      catch(Exception exception)
      {
      out.println("Exception Caught");
      }

      Here is variable-s is passed as '', it would throw NumberFormatException which would be caught by catch block.

      Compile-time Exception: xx_ibeCCtdMenu.jsp
      try
      {
      ...
      callablestatement.etBigDecimal(1, new BigDecimal(s));
      ...
      }
      catch(Exception exception)
      {
      out.println("Exception Caught");
      }

      Here I have misspelled 'setBigDecimal' method, so it would not be able to generate class file - xx_ibeCCtdMenu.class. But on front end (iStore Customer UI) it would just give blank page. Catch block can not handle this type of error.

      To find exact error, I have to get Apache Log (which take time to submit internal request in our org) or compile xx_ibeCCtdMenu.java file from _pages directory (there are so many unrelated excpetions).

      I know this type of exception is handled well in R12.

      Appreciate your feedback if could help me to find way to handle compile-time exception in jsp without going to apache log or manually compiling.

      Thanks in advanced.