Re: Problem with a store procedure in a XSP page

2002-11-24 Thread neil
Since the 2.0.3 release there have been fixes applied to esql in the 
cocoon_2_0_3_branch (that's a CVS tag). These fixes are for
stored procedure support, so I suggest you try them. I've been using them with stored 
procs in Oracle 8i, SQL Server (7  2000),
Sybase (ASA  ASE) and it works great.


-
Please check that your question  has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faq/index.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail:   [EMAIL PROTECTED]




Problem with a store procedure in a XSP page

2002-11-23 Thread Saul Rodrigo Zarrate Cárdenas
Hello

I have a cocoon version number 2.0.3, a tomcat version number 4.1.12, a 
j2sdk1.4.0_02 and an Oracle 8i database

I have a store procedure in my database called validar and it is in a 
package.  The name of the package is JBDPL.  I tested the store procedure and 
it doesn't have any problem.  It has 3 parameters.  The first and the second 
are in parameters, and must be String.  The third is an out parameter and must 
be integer.

The name of the page is validar.xsp

The source of this page is

?xml version=1.0 encoding=ISO-8859-1? 
 
xsp:page language=java
   xmlns:xsp=http://apache.org/xsp;
   xmlns:esql=http://apache.org/cocoon/SQL/v2;
   xmlns:xsp-request=http://apache.org/xsp/request/2.0;
  
   
 page 

  title/title

  content
   esql:connection 

esql:poolsgcWebXML_oracle_pool/esql:pool

 esql:execute-query 

  esql:call
   { CALL JBDPL.validar ( esql:parameter direction=in 
type=Stringxsp-request:get-parameter 
name=funcionariotextfield//esql:parameter
   ,esql:parameter direction=in 
type=StringOracle/esql:parameter
   ,esql:parameter direction=out type=Int/esql:parameter
   )
   }
  /esql:call

 /esql:execute-query
 /esql:connection
   /content
  /page
/xsp:page

In the sitemap I have 

   map:match pattern=validar.xsp
map:generate type=serverpages src=validar.xsp/
map:serialize type=xml/
   /map:match


When I tried to load the page I have the next problem

Cocoon 2 - Internal server error

---
-

type fatal

message Exception in ServerPagesGenerator.generate()

description org.apache.cocoon.ProcessingException: Exception in 
ServerPagesGenerator.generate(): java.lang.NullPointerException

sender org.apache.cocoon.servlet.CocoonServlet

source Cocoon servlet

stack-trace

org.apache.cocoon.ProcessingException: Exception in 
ServerPagesGenerator.generate(): java.lang.NullPointerException
at org.apache.cocoon.generation.ServerPagesGenerator.generate
(ServerPagesGenerator.java:270)
at org.apache.cocoon.components.pipeline.CachingEventPipeline.process
(CachingEventPipeline.java:250)
at org.apache.cocoon.components.pipeline.CachingStreamPipeline.process
(CachingStreamPipeline.java:399)
at org.apache.cocoon.www.SGCWebXML.sitemap_xmap.matchN4000B2
(C:\Archivos de programa\Apache Group\Tomcat 4.1
\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www/SGCWebXML\sitemap_xmap.java:1037)
at org.apache.cocoon.www.SGCWebXML.sitemap_xmap.process(C:\Archivos 
de programa\Apache Group\Tomcat 4.1\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www/SGCWebXML\sitemap_xmap.java:484)
at org.apache.cocoon.www.SGCWebXML.sitemap_xmap.process(C:\Archivos 
de programa\Apache Group\Tomcat 4.1\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www/SGCWebXML\sitemap_xmap.java:397)
at org.apache.cocoon.sitemap.Handler.process(Handler.java:224)
at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
at org.apache.cocoon.www.sitemap_xmap.matchN4002C9(C:\Archivos de 
programa\Apache Group\Tomcat 4.1\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www\sitemap_xmap.java:3337)
at org.apache.cocoon.www.sitemap_xmap.process(C:\Archivos de 
programa\Apache Group\Tomcat 4.1\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www\sitemap_xmap.java:2579)
at org.apache.cocoon.www.sitemap_xmap.process(C:\Archivos de 
programa\Apache Group\Tomcat 4.1\work\Standalone\localhost\cocoon\cocoon-
files\org/apache/cocoon/www\sitemap_xmap.java:2516)
at org.apache.cocoon.sitemap.Handler.process(Handler.java:224)
at org.apache.cocoon.sitemap.Manager.invoke(Manager.java:179)
at org.apache.cocoon.sitemap.SitemapManager.process
(SitemapManager.java:154)
at org.apache.cocoon.Cocoon.process(Cocoon.java:575)
at org.apache.cocoon.servlet.CocoonServlet.service
(CocoonServlet.java:999)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter
(ApplicationFilterChain.java:247)
at org.apache.catalina.core.ApplicationFilterChain.doFilter
(ApplicationFilterChain.java:193)
at org.apache.catalina.core.StandardWrapperValve.invoke
(StandardWrapperValve.java:260)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNe
xt(StandardPipeline.java:643)
at org.apache.catalina.core.StandardPipeline.invoke
(StandardPipeline.java:480)
at org.apache.catalina.core.ContainerBase.invoke
(ContainerBase.java:995)
at org.apache.catalina.core.StandardContextValve.invoke
(StandardContextValve.java:191)
at 
org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNe
xt(StandardPipeline.java:643)
at