XML - DB

2001-08-21 Thread Gustavo Mejia

Hello my friends,

I am here again, sorry if I am bothering you, maybe it is not the
correct list,  I have near a project and I have to read and XML document
and make a process for inserting the records of this document into an
Oracle Data Base, could you give an idea in order to do this ?? If you
have a brief example should be great!!

Thanks in advance !!

Gustavo Mejia
--
Gustavo Mejía Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



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

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




Question displaying results HTML Cocoon.

2001-08-14 Thread Gustavo Mejia


Hello everyone,,

Maybe it is not related with this list, but maybe you know, I am trying
to show all my records using an HTML with xmldso and other file XML using
esql tags, If call just the esql file It works fine, but when I call it
by my HTML, when I press next I got an error message that says that
the action is not allowed because the object is not opened.
here is my HTML code.
!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
html>
head>
script type="text/javascript">
function movenext()
{
x=xmldso.recordset
if (x.absoluteposition  x.recordcount)
{
x.movenext()
}
}
function moveprevious()
{
x=xmldso.recordset
if (x.absoluteposition > 1)
{
x.moveprevious()
}
}
/script>
/head>
body>
xml src="/cocoon/servlet/sql/sql_2.xml" id="xmldso" async="false">/xml>
p>
Nombre:
input type="text" datasrc="#xmldso" datafld="empno">/input>
br />Nickname:
input type="text" datasrc="#xmldso" datafld="fisrtname">/input>
br />Edad:
input type="text" datasrc="#xmldso" datafld="lastname">/input>
br />Sexo:
input type="text" datasrc="#xmldso" datafld="salary">/input>
br />Color:
input type="text" datasrc="#xmldso" datafld="job">/input>
/p>
p>
input type="button" value="Anterior"  />
input type="button" value="next"  />
/p>
/body>
/html>
I am using cocoon 1.8.2, Tomcat 3.2.1, I'm going to appreciate all your
help !
Thanks !
--
Gustavo Meja Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



Weblogic6.0 and Cocoon 1.8.2

2001-07-31 Thread Gustavo Mejia

Hello Everyone,

Sorry for the trouble, but I was reading the Mail Achive, and my problem
is already there, but I follow every step described and I can't make it
work, I run
http://localhost:7001/cocoon/Cocoon.xml and it works fine, but when I
try other sample appear the next message.

java.lang.RuntimeException: Cannot access non-file/war resources
 at org.apache.cocoon.Utils.getBasename(Utils.java:277)
 at
org.apache.cocoon.producer.ProducerFromFile.getDocument(ProducerFromFile.java:76)

 at org.apache.cocoon.Engine.handle(Engine.java:359)
 at org.apache.cocoon.Cocoon.service(Cocoon.java:183)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
 at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:213)

 at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:1265)

 at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:1631)

 at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
 at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)

I am using

weblogic6.0
Cocoon 1.8.2
NT


If someone knows how to fix this problem give the tip !!

Thanks a lot !!

--
Gustavo Mejía Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



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

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




ESQL Cocoon problem (string length)

2001-07-05 Thread Gustavo Mejia

Hello !!

I have the same problem that Matthew had, did someone get the solution
??  how can I fix it ??

Thanks for your help !!

*



Hi Matthew,

It looks like the column that is causing problems is of type VARCHAR2
with a
size of 64.  I have a sneaking suspision that this is what is causing my

problem.  I use the following code.  POPIS is the problem column that I
think is causing the problem:

!-- QUERY FOR ALL CODES --
esql:connection
  esql:pooldefault/esql:pool
  esql:execute-query
esql:query
 select CSKS_ID CSKS_ID1, POPIS POPIS1,
TO_CHAR(PLATNOST_OD,'DD.MM.') PLATNOST_OD1
 from cis_konst_symbol
 order by POPIS
/esql:query
esql:results
  esql:row-results
 row
csks_id1esql:get-string column=CSKS_ID1//csks_id1
popis1esql:get-string column=POPIS1//popis1
platnost_od1esql:get-string
column=PLATNOST_OD1//platnost_od1
 /row
  /esql:row-results
/esql:results
esql:no-results
  rowcsks_id1 /csks_id1/row
/esql:no-results
  /esql:execute-query
/esql:connection

I think the column is too big--like a blob datatype.

Regards,
Robert Mayer



 -Pùvodní zpráva-
 Od: Matthew Cordes [SMTP:[EMAIL PROTECTED]]
 Odesláno: Monday, May 14, 2001 9:54 PM
 Komu: [EMAIL PROTECTED]
 Pøedmìt: Re: ESQL Cocoon problem

 Hi,

 What datatype are you storing your data in?  I had this problem with a

 clob, which I was treating as though it was a string (e.g.
 ResultSet.getString() ). If this is the case oracle has some special

 clob/blob releated methods/classes, read the html documentation
 that comes with the server.

 -matt


 On Mon, May 14, 2001 at 01:57:06PM -0400, Donald Ball wrote:
  On Mon, 14 May 2001 [EMAIL PROTECTED] wrote:
 
   I have a problem with the HTML table being cut off in my combined
 XML/XSL
   file.  I use ESQL tags and do a query (The query does work
properly in
   Oracle SQL Plus.) in our Oracle database.  Using Cocoon, I put the

 column
   results into a HTML table and the data is cut off at some point in
the
   table.  Also when I look at the raw data coming through, the data
gets
 cut
   of at about row 30 and there should be about 200 rows displayed
from
 the
   query.  In my select statement I query 3 columns.  When I comment
out
 the 2nd column of the HTML table all the data (minus that column) are
 presented in the combined XML file OK.  In summary, Cocoon is not able
to
 display all the data that is presented by the query using ESQL tags?
Why is this?
 Have there been similar problems reported?  Is there a fix?
 
  there are no limitations on query size using esql.
 
  - donald
 


--
Gustavo Mejía Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



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

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




Re: Displaying Images ?

2001-07-03 Thread Gustavo Mejia

Yeap !!

Thanks Mohamed !! I´m going to do that !!

--
Gustavo Mejía Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



Mohamed Ramzy wrote:

 hi,
 the idea is simpleget the name of the image file
 from ur database by using esql(as u use it), then pass
 it to the XSL file as a tag and put it through
 variable and write the normal HTML imag tag, and in
 the source field write the name of ur variable
 i hope that can help
 --- Gustavo Mejia [EMAIL PROTECTED] wrote:
  Hello !!
 
  Yes, I am here again .. I have a question, I need to
  display an image
  stored in my Oracle Database, I'm using esql, to get
  the information,
  but I I don't know how to get the pic's.
 
  I would appreciate all your Ideas and help !
 
  Thanks in advance.
 
  Gustavo
  INFOTEC
 
 
 
 -
  Please check that your question has not already been
  answered in the
  FAQ before posting.
  http://xml.apache.org/cocoon/faqs.html
 
  To unsubscribe, e-mail:
  [EMAIL PROTECTED]
  For additional commands, e-mail:
  [EMAIL PROTECTED]
 

 =
 Mohamed Ramzy Zakaria, Graduate Research student
 School of Computer Science  Information Technology
 Jubilee Campus, Nottingham University
 Nottingham, UK
 TEL: 00 44 (0)115 84 66529
 MOB: 00 44 (0)7947105251
 MOB E-MAIL: [EMAIL PROTECTED]

 __
 Do You Yahoo!?
 Get personalized email addresses from Yahoo! Mail
 http://personal.mail.yahoo.com/

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

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





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

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




Query problems !

2001-07-03 Thread Gustavo Mejia


Hi !!
I am making a query passing it from a JSP file, my code is very simple
but I got an error:
java.lang.RuntimeException:
Error executed prepared statement:
?
at _C_._tomcat._webapps._cocoon._m3._query_m3.populateDocument(_query_m3.java:233)
at org.apache.cocoon.processor.xsp.XSPPage.getDocument(XSPPage.java:97)
at org.apache.cocoon.processor.xsp.XSPProcessor.process(XSPProcessor.java:527)
at org.apache.cocoon.Engine.handle(Engine.java:384)
at org.apache.cocoon.Cocoon.service(Cocoon.java:183)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)
My code is the next:
esql:query>
 esql:parameter type="string">
 request:get-parameter name="pQuery"/>
 /esql:parameter>
/esql:query>
and I send the variable pQuery using the URL, something like:
http://localhost/cocoon/m3/query_m3.xml?pQuery=select * from inmuebles
I don't know what the error is, I think it is because the spaces in
the query, I tried also putting my query directly, (no like a parameter)
and it works fine.
Could you help me ? how can I fix this error !!
I would appreciate all your help !
Thanks a lot
--
Gustavo Meja Mora
INFOTEC
Tel: 5624 28 00
Ext: 253



Displaying Images ?

2001-06-28 Thread Gustavo Mejia

Hello everyone,

  I have a question, I need to display an image
 stored in my Oracle Database, I'm using esql, to get the information,
 but  I don't know how to get the pic's, could you give a guide ?.

 I would appreciate all your Ideas and help !

 Thanks in advance.

 Gustavo
 INFOTEC

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

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


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

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




Re: work around for xsl:text disable-output-escaping=yes?

2001-06-27 Thread Gustavo Mejia


Hi,
I think you can use Xalan extention, (Redirect) somethink like :
xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 version="1.0"
 xmlns:lxslt="http://xml.apache.org/xslt"
 xmlns:redirect="org.apache.xalan.xslt.extensions.Redirect"
 extension-element-prefixes="redirect">
...
...
...
redirect:write select="Your_file">
...
...
...
/redirect:write>
/xsl:stylesheet>

Robert McKinnon wrote:
Hello,
I am trying to dynamically build table rows from an xml file.
The solution
that I came across indicated that I would need to use xsl:text
disable-output-escaping="yes">. When I tried to apply this solution
I
discovered that Cocoon does not support disable-output-escaping.
What would
be an alternative solution? The following are example snippets:
[XML]
parent>
 child>

name>child1/name>
 /child>
 child>

name>child2/name>
 /child>
 child>

name>child3/name>
 /child>
 child>

name>child4/name>
 /child>
 child>

name>child5/name>
 /child>
 child>

name>child6/name>
 /child>
/parent>
[OUTPUT DESIRED]
tr>
 td>child1/td>
 td>child2/td>
/tr>
tr>
 td>child3/td>
 td>child4/td>
/tr>
tr>
 td>child5/td>
 td>child6/td>
/tr>
[RECOMMENDED XSL SOLUTION NOT SUPPORTED BY COCOON]
tr>
xsl:for-each select="parent/child">
 td>xsl:value-of
select="name"/>/td>
 xsl:if test="position()
mod 2 = 0">

xsl:text disable-output-escaping="yes">

![CDATA[/tr>tr>]]>

/xsl:text>
 /xsl:if>
/xsl:for-each>
/tr>
-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: [EMAIL PROTECTED]>
For additional commands, e-mail: [EMAIL PROTECTED]>



Displaying Images ?

2001-06-27 Thread Gustavo Mejia

Hello !!

Yes, I am here again .. I have a question, I need to display an image
stored in my Oracle Database, I'm using esql, to get the information,
but I I don't know how to get the pic's.

I would appreciate all your Ideas and help !

Thanks in advance.

Gustavo
INFOTEC


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

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




Re: how can I redirect my Result ? Using fp tag

2001-06-26 Thread Gustavo Mejia


Hello !!
Anybody read my message ?? any idea ?? please, I need your help !!
I still trying but I don't get it !
Gustavo !

Gustavo Mejia wrote:
Hi,
I am still trying to save my XML to a file, I am using
fp tags, here I am trying to get and to save the field empno from
the employee table, I need just exactly the same thing that I got in my
browser, but now in a file (including the tags that describe the information
of the field), but it doesn't work,
please ! I need your help !!
Here my code,
thanks a lot and sorry for the trouble !
Gustavo
?xml version="1.0"?>
?cocoon-process type="xsp"?>
xsp:page
 xmlns:fp="http://apache.org/cocoon/XSP/FP/1.0"
 xmlns:request="http://www.apache.org/1999/XSP/Request"
 xmlns:xsp="http://www.apache.org/1999/XSP/Core"
 xmlns:esql="http://apache.org/cocoon/SQL/v2"
>
fp:resource id="external-item">
fp:resource-file>resulta.xml/fp:resource-file>
 fp:resource-node>//fp:resource-node>
fp:default-mode>replace/fp:default-mode>
/fp:resource>
page>
esql:connection>
 esql:driver>oracle.jdbc.driver.OracleDriver/esql:driver>
 esql:dburl>jdbc:oracle:thin:@204.153.24.233:1521:cta/esql:dburl>
 esql:username>user/esql:username>
 esql:password>password/esql:password>
 esql:execute-query>
 esql:query>
 select
* from employee order by empno
 /esql:query>
 esql:results>
 header>Prueba ESQL
para el CTA: /header>
 esql:row-results>
 empleado>

fp:write to="external-item" select="column/empno as="string">

request:get-parameter name="empno"/>

/fp:write>
 /empleado
>
 /esql:row-results>
 footer>Aqui puede
ir un pie de pagina/footer>
 /esql:results>
 /esql:execute-query>
/esql:connection>
/page>
/xsp:page>
Gustavo Mejia wrote:
Hi, sorry for the troubles but I am here again !
Could somebody tell how can I use FP tags in order to save my XML resulted
from query ? Here my code.
?xml version="1.0"?>
?cocoon-process type="xsp"?>
xsp:page
 xmlns:fp="http://apache.org/cocoon/XSP/FP/1.0"
 xmlns:request="http://www.apache.org/1999/XSP/Request"
 xmlns:xsp="http://www.apache.org/1999/XSP/Core"
 xmlns:esql="http://apache.org/cocoon/SQL/v2"
>
page>
xsp:logic>
 Date
now = new Date();
/xsp:logic>
esql:connection>
 esql:driver>oracle.jdbc.driver.OracleDriver/esql:driver>
 esql:dburl>jdbc:oracle:thin:@My_IP:1521:cta/esql:dburl>
 esql:username>user/esql:username>
 esql:password>password/esql:password>
 esql:execute-query>

esql:query>

select * from employee

where empno=esql:parameter type="string">request:get-parameter
name="EMP_CLVE"/>/esql:parameter>

or sex=esql:parameter type="string">request:get-parameter name="EMP_SEX"/>/esql:parameter>

or sex=esql:parameter type="string">request:get-parameter name="EMP_SEX2"/>/esql:parameter>

or birtdate=TO_DATE(esql:parameter type="string">request:get-parameter
name="EMP_BIR"/>/esql:parameter>,'DD/MM/')

order by empno

/esql:query>
 esql:results>

header>Prueba ESQL para el CTA Fecha de hoy : xsp:expr>now/xsp:expr>/header>

esql:row-results>

empleado>

empno>esql:get-int column="empno"/>/empno>

fisrtname>esql:get-string column="fisrtname"/>/fisrtname>

lastname>esql:get-string column="lastname"/>/lastname>

salary>esql:get-int column="salary"/>/salary>

job>esql:get-string column="job"/>/job>

sexo>esql:get-string column="sex"/>/sexo>

fecha>esql:get-date column="birtdate"/>/fecha>

phone>esql:get-string column="phoneno"/>/phone>

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>

select * from Departamento

where empno = esql:parameter type="int">esql:get-int ancestor="1"
column="empno"/>/esql:parameter>

/esql:query>

esql:results>

esql:row-results>

depto>esql:get-int column="Departamento"/>/depto>

/esql:row-results>

/esql:results>

esql:no-results>

depto>No hay depto/depto>

/esql:no-results>

/esql:execute-query>

/esql:connection>

/empleado >

/esql:row-results>

footer>Aqui puede ir un pie de pagina/footer>
 /esql:results>
 /esql:execute-query>
/esql:connection>
/page>
/xsp:page>

Thanks a lot !
Gustavo


Gustavo Mejia wrote:
And, also, how can I save this results into an specific
file automataclly ??
Any Idea..

how can I redirect my Result ?

2001-06-25 Thread Gustavo Mejia

Hi !

I am here again !

I have a question, I have a very small application that makes a query to
my database, when I make the request I got the result in other XML
document but in my same page (well y the same browser) the question is,
how can I redirect the results, in order that this results appear in the
URL that I define, is it posiible, ?? how can I do that ?

Please !! help me !!!

Thanks a lot !!!
Gustavo




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

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




how can I redirect my Result ?

2001-06-25 Thread Gustavo Mejia

And, also, how can I save this results into an specific file automataclly ??

Any Idea.. ?? I really appreciate all your help !!!

Gustavo


Gustavo Mejia wrote:

 Hi !

 I am here again !

 I have a question, I have a very small application that makes a query to
 my database, when I make the request I got the result in other XML
 document but in my same page (well y the same browser) the question is,
 how can I redirect the results, in order that this results appear in the
 URL that I define, is it posiible, ?? how can I do that ?

 Please !! help me !!!

 Thanks a lot !!!
 Gustavo

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

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


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

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




how can I redirect my Result ? Using fp tag

2001-06-25 Thread Gustavo Mejia


Hi, sorry for the troubles but I am here again !
Could somebody tell how can I use FP tags in order to save my XML resulted
from query ? Here my code.
?xml version="1.0"?>
?cocoon-process type="xsp"?>
xsp:page
 xmlns:fp="http://apache.org/cocoon/XSP/FP/1.0"
 xmlns:request="http://www.apache.org/1999/XSP/Request"
 xmlns:xsp="http://www.apache.org/1999/XSP/Core"
 xmlns:esql="http://apache.org/cocoon/SQL/v2"
>
page>
xsp:logic>
 Date
now = new Date();
/xsp:logic>
esql:connection>
 esql:driver>oracle.jdbc.driver.OracleDriver/esql:driver>
 esql:dburl>jdbc:oracle:thin:@My_IP:1521:cta/esql:dburl>
 esql:username>user/esql:username>
 esql:password>password/esql:password>
 esql:execute-query>


esql:query>

select * from employee

where empno=esql:parameter type="string">request:get-parameter
name="EMP_CLVE"/>/esql:parameter>

or sex=esql:parameter type="string">request:get-parameter name="EMP_SEX"/>/esql:parameter>

or sex=esql:parameter type="string">request:get-parameter name="EMP_SEX2"/>/esql:parameter>

or birtdate=TO_DATE(esql:parameter type="string">request:get-parameter
name="EMP_BIR"/>/esql:parameter>,'DD/MM/')

order by empno

/esql:query>

 esql:results>

header>Prueba ESQL para el CTA Fecha de hoy : xsp:expr>now/xsp:expr>/header>

esql:row-results>

empleado>

empno>esql:get-int column="empno"/>/empno>

fisrtname>esql:get-string column="fisrtname"/>/fisrtname>

lastname>esql:get-string column="lastname"/>/lastname>

salary>esql:get-int column="salary"/>/salary>

job>esql:get-string column="job"/>/job>

sexo>esql:get-string column="sex"/>/sexo>

fecha>esql:get-date column="birtdate"/>/fecha>

phone>esql:get-string column="phoneno"/>/phone>

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>

select * from Departamento

where empno = esql:parameter type="int">esql:get-int ancestor="1"
column="empno"/>/esql:parameter>

/esql:query>

esql:results>

esql:row-results>

depto>esql:get-int column="Departamento"/>/depto>

/esql:row-results>

/esql:results>

esql:no-results>

depto>No hay depto/depto>

/esql:no-results>

/esql:execute-query>

/esql:connection>

/empleado >

/esql:row-results>

footer>Aqui puede ir un pie de pagina/footer>
 /esql:results>
 /esql:execute-query>
/esql:connection>
/page>
/xsp:page>

Thanks a lot !
Gustavo


Gustavo Mejia wrote:
And, also, how can I save this results into an specific
file automataclly ??
Any Idea.. ?? I really appreciate all your help !!!
Gustavo
Gustavo Mejia wrote:
> Hi !
>
> I am here again !
>
> I have a question, I have a very small application that makes a query
to
> my database, when I make the request I got the result in other XML
> document but in my same page (well y the same browser) the question
is,
> how can I redirect the results, in order that this results appear
in the
> URL that I define, is it posiible, ?? how can I do that ?
>
> Please !! help me !!!
>
> Thanks a lot !!!
> Gustavo
>
> -
> Please check that your question has not already been answered in
the
> FAQ before posting. http://xml.apache.org/cocoon/faqs.html>
>
> To unsubscribe, e-mail: [EMAIL PROTECTED]>
> For additional commands, e-mail: [EMAIL PROTECTED]>
-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: [EMAIL PROTECTED]>
For additional commands, e-mail: [EMAIL PROTECTED]>



Question !

2001-06-22 Thread Gustavo Mejia

Hi !

I have a question, how can I read an XML (result from a query) using an other
XML, imaging that it is in other computer ? the first XML, could be something
like the data source to be used  with other XML, You know what I mean ?

Any Idea ?

Thanks a lot for your help

Gustavo


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

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




Re: I think I know why Cocoon / Tomcat can't work on windows

2001-06-22 Thread Gustavo Mejia

Hi Pete,

I am working with Cocoon 1.8.2 on W98 and Tomcat 3.2.1 and it's working
fine, what I change was the tomcat.bat, there I disabled the dynamic
Classpath, and works with the static classpath, there you can define the
order to load the classes.

Gustavo

Pete Nelson wrote:

 I've been trying for several weeks to get cocoon (1.8.2) to work with
 tomcat (3.2.2) on Windows (98SE, ME, and 2000 Pro) with jdk1.3.  I think
 I may have figured out why it won't work.

 The problem is that parts of tomcat (org.apache.tomcat.util.xml.*)
 require the older xml parsing libraries.  While this is okay under a
 more full-featured OS, windows doesn't seperate the processing
 environments between tomcat  cocoon - so unless there's a way to start
 up cocoon before tomcat, the older parsers will always be loaded first.

 It would seem the only answer would be to fix
 org.apache.tomcat.util.xml.* in Tomcat.  Or maybe better - don't use
 windows (If only I could convince my bosses of that solution!).

 I've got a developer license of JRun, so I guess I'll hang my head and
 go that route.

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

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


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

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




SOAP

2001-06-20 Thread Gustavo Mejia

Hi everyone,

Someone can explain me what is SOAP for ? is there a relation with
Cocoon ? what is that relation ?

Thanks a lot !

Gustavo
INFOTEC


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

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




Re: ERROR Publishing Engine could not be initialized.

2001-06-20 Thread Gustavo Mejia


I had the same problem, so I modified the tomcat.bat, and also my Classpath,
checking that all the classes from Cocoon/lib are in Tomcat_Home/lib
You have to check that appears at the begining of your configuration
the package xerces.jar, if it is not your are going to get the error.
here is my Tomcat.bat.
set _CP=%CP%
set _TOMCAT_HOME=%TOMCAT_HOME%
set _CLASSPATH=%CLASSPATH%

rem - Verify and Set Required Environment Variables
-
if not "%JAVA_HOME%" == "" goto gotJavaHome
echo You must set JAVA_HOME to point at your Java Development
Kit installation
goto cleanup
:gotJavaHome
if not "%TOMCAT_HOME%" == "" goto gotTomcatHome
set TOMCAT_HOME=.
:gotTomcatHome
if exist "%TOMCAT_HOME%\lib\servlet.jar" goto okTomcatHome
echo Unable to locate servlet.jar, check the value of
TOMCAT_HOME.
goto cleanup
:okTomcatHome

rem - Prepare Appropriate Java Execution Commands
---
if not "%OS%" == "Windows_NT" goto noTitle
set _SECSTARTJAVA=start "Secure Tomcat 3.2" "%JAVA_HOME%\bin\java"
set _STARTJAVA=start "Tomcat 3.2" "%JAVA_HOME%\bin\java"
set _RUNJAVA="%JAVA_HOME%\bin\java"
goto setClasspath
:noTitle
set _SECSTARTJAVA=start "%JAVA_HOME%\bin\java"
set _STARTJAVA=start "%JAVA_HOME%\bin\java"
set _RUNJAVA="%JAVA_HOME%\bin\java"

rem - Set Up The Runtime Classpath --
:setClasspath
set CP=%TOMCAT_HOME%\classes
rem Try to determine if TOMCAT_HOME
contains spaces
rem if exist %TOMCAT_HOME%\lib\servlet.jar
goto dynClasspath
echo Your TOMCAT_HOME appears to contain spaces.
echo Unable to set CLASSPATH dynamically.
goto staticClasspath
rem:dynClasspath
rem set _LIBJARS=
rem for %%i in (%TOMCAT_HOME%\lib\*.jar)
do call %TOMCAT_HOME%\bin\cpappend.bat %%i
rem if not "%_LIBJARS%" == "" goto
gotLibJars
rem echo Unable to set CLASSPATH
dynamically.
remif "%OS%" == "Windows_NT" goto
staticClasspath
rem echo Note: To set the CLASSPATH
dynamically on Win9x systems
rem echo
only DOS 8.3 names may be used in TOMCAT_HOME!
rem goto staticClasspath
rem :gotLibJars
rem echo Including all jars in
%TOMCAT_HOME%\lib in your CLASSPATH.
rem Note: _LIBJARS already contains
a leading semicolon
rem set CP=%CP%%_LIBJARS%
rem goto chkClasspath
:staticClasspath
echo Setting your CLASSPATH statically.
if exist "%TOMCAT_HOME%\lib\axerces.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\axerces.jar
if exist "%TOMCAT_HOME%\lib\zant.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\zant.jar
if exist "%TOMCAT_HOME%\lib\jasper.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\jasper.jar
if exist "%TOMCAT_HOME%\lib\jaxp.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\jaxp.jar
if exist "%TOMCAT_HOME%\lib\parser.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\parser.jar
if exist "%TOMCAT_HOME%\lib\servlet.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\servlet.jar
if exist "%TOMCAT_HOME%\lib\webserver.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\webserver.jar
if exist "%TOMCAT_HOME%\lib\cocoon.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\cocoon.jar
if exist "%TOMCAT_HOME%\lib\fesi.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\fesi.jar
if exist "%TOMCAT_HOME%\lib\sax-bugfix.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\sax-bugfix.jar
if exist "%TOMCAT_HOME%\lib\w3c.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\w3x.jar
if exist "%TOMCAT_HOME%\lib\xml.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\xml.jar
if exist "%TOMCAT_HOME%\lib\xt.jar"
set CP=%CP%;%TOMCAT_HOME%\lib\xt.jar
:chkClasspath
if "%CLASSPATH%" == "" goto noClasspath
set CP=%CP%;%CLASSPATH%
:noClasspath
if not exist "%JAVA_HOME%\lib\tools.jar" goto installClasspath
set CP=%CP%;%JAVA_HOME%\lib\tools.jar
:installClasspath
echo.
echo Using CLASSPATH: %CP%
echo.
set CLASSPATH=%CP%
rem - Execute The Requested Command -
if "%1" == "start" goto startServer
if "%1" == "stop" goto stopServer
if "%1" == "run" goto runServer
if "%1" == "ant" goto runAnt
if "%1" == "env" goto doEnv
if "%1" == "jspc" goto runJspc
:doUsage
echo Usage: tomcat ( ant ^| env ^| jspc ^| run
^| start ^| stop )
echo Commands:
echo ant - Run Ant in Tomcat's
environment
echo env - Set up environment
variables that Tomcat would use
echo jspc - Run JSPC in Tomcat's environment
echo run - Start Tomcat in the
current window
echo start - Start Tomcat in a separate window
echo stop - Stop Tomcat
goto cleanup
:doEnv
goto finish
:startServer
echo Starting Tomcat in new window
if "%2" == "-security" goto startSecure
%_STARTJAVA% %TOMCAT_OPTS% -Dtomcat.home="%TOMCAT_HOME%"
org.apache.tomcat.startup.Tomcat %2 %3 %4 %5 %6 %7 %8 %9
goto cleanup
:startSecure
echo Starting Tomcat with a SecurityManager
%_SECSTARTJAVA% %TOMCAT_OPTS% -Djava.security.manager
-Djava.security.policy=="%TOMCAT_HOME%/conf/tomcat.policy" -Dtomcat.home="%TOMCAT_HOME%"
org.apache.tomcat.startup.Tomcat %3 %4 %5
%6 %7 %8 %9
goto cleanup
:runServer
rem Running Tomcat in this window
if "%2" == "-security" goto runSecure
%_RUNJAVA% %TOMCAT_OPTS% -Dtomcat.home="%TOMCAT_HOME%"
org.apache.tomcat.startup.Tomcat %2 %3 %4 %5 %6 %7 %8 %9
goto cleanup
:runSecure
rem Running Tomcat with a SecurityManager
%_RUNJAVA% 

Re:How can I make a validation !

2001-06-19 Thread Gustavo Mejia


Hi everyone,
I got it, the problem was when I tried to compare with null, I don't
know why Cocoon doesn't recongnize the condition if (Test !=null),
could this be a bug ?, in other to make it works I change to:
xsp:logic>
String Test;
Test = request.getParameter("EMP_DEP");
 if (Test.length() !=0)
 {
 my_code
 }
/xsp:logic>

See you.
Gustavo

Gustavo Mejia wrote:
Hi Pal,
Thanks, I also tried this, with no good results, still passing to the
code, that I need to skip.
:(
any other Idea is very wellcome !!
Thanks !!


Pal Wester wrote:
Why
not just use request.getParameter("EMP_DEP") when ur in a javablock...xsp:logic>

if ( request.getParameter("EMP_DEP") != null )

{

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>insert into Departamento values(

esql:parameter type="string">request:get-parameter name="EMP_CLVE"/>/esql:parameter>,

esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>

)

/esql:query>

/esql:execute-query>

/esql:connection>

}
/xsp:logic>
mvh:
Pl
Wester
hgskoleingenr/programmerer

never.no
as, stortingsgt
30, 0161 Oslo
direkte: 22 01 66 34, 906 900 62
tlf: 22 01 66 34, fax: 22 01 66 21
http://never.no
- icq:103476059

Re: How can I make a validation !

2001-06-18 Thread Gustavo Mejia


Hi !
Any notice about this issue ???
I am going to appreciate all your help !!

Gustavo Mejia

Gustavo Mejia wrote:
Hi everyone
!!
I am trying to make a validation
in order to skip part of my code (I want to skip the connection to my database),
I am doing something like this:
xsp:logic>

if (esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>
!= nul)

{

xsp:expr>

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>insert into Departamento values(

esql:parameter type="string">request:get-parameter name="EMP_CLVE"/>/esql:parameter>,

esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>

)

/esql:query>

/esql:execute-query>

/esql:connection>

/xsp:expr>

}
/xsp:logic>
But
it doesn't work, I got the message :
java.lang.Exception:
XSP Java Compiler: Compilation failed for _nuevo.java
433:
')' expected.

xspParentNode = xspCurrentNode;
Could
you help me ? do you know what I am doing wrong ?
Thanks
in advance !!
Gustavo
Mejia
INFOTEC




Re: How can I make a validation !

2001-06-18 Thread Gustavo Mejia


Thanks Vadim,
I tried but doesn't work, now the message is:
java.lang.RuntimeException: Error executed prepared statement: insert
into Departamento values
Vadim Gritsenko wrote:
Why
do you use esql:parameter> here:
if (esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>
!= nul)Why
not just
if (request:get-parameter name="EMP_DEP"/> != nul)?This
might solve your problem.Vadim

-Original
Message-
From: Gustavo Mejia [mailto:[EMAIL PROTECTED]]
Sent: Monday, June 18, 2001
15:03
To: [EMAIL PROTECTED]
Subject: Re: How can I make
a validation !
Importance: High

Hi !
Any notice about this issue ???
I am going to appreciate all your help !!

Gustavo Mejia

Gustavo Mejia wrote:
Hi everyone
!!
I am trying to make a validation
in order to skip part of my code (I want to skip the connection to my database),
I am doing something like this:
xsp:logic>

if (esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>
!= nul)

{

xsp:expr>

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>insert into Departamento values(

esql:parameter type="string">request:get-parameter name="EMP_CLVE"/>/esql:parameter>,

esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>

)

/esql:query>

/esql:execute-query>

/esql:connection>

/xsp:expr>

}
/xsp:logic>
But
it doesn't work, I got the message :
java.lang.Exception:
XSP Java Compiler: Compilation failed for _nuevo.java
433:
')' expected.

xspParentNode = xspCurrentNode;
Could
you help me ? do you know what I am doing wrong ?
Thanks
in advance !!
Gustavo
Mejia
INFOTEC






Re: How can I make a validation !

2001-06-18 Thread Gustavo Mejia



Hi everyone
!!
Now my problem is: I know that my variable EMP_DEP is null, and I don't
know why is passing to the connection section.and if I add one line with:
System.out.println(" enter " + request:get-parameter
name="EMP_DEP"/>);
before star the connection, just appear "enter".
Do you know why ?? here my code !

xsp:logic>

if (request:get-parameter name="EMP_DEP"/> != null)

{

esql:connection>

esql:driver>sun.jdbc.odbc.JdbcOdbcDriver/esql:driver>

esql:dburl>JDBC:ODBC:SQL/esql:dburl>

esql:username>user/esql:username>

esql:password>password/esql:password>

esql:execute-query>

esql:query>insert into Departamento values(

esql:parameter type="string">request:get-parameter name="EMP_CLVE"/>/esql:parameter>,

esql:parameter type="string">request:get-parameter name="EMP_DEP"/>/esql:parameter>

)

/esql:query>

/esql:execute-query>

/esql:connection>

}
/xsp:logic>
But
it doesn't work, I got the message :
java.lang.Exception:
XSP Java Compiler: Compilation failed for _nuevo.java
433:
')' expected.

xspParentNode = xspCurrentNode;
Could
you help me ? do you know what I am doing wrong ?
Thanks
in advance !!
Gustavo
Mejia
INFOTEC




Problem with my query

2001-06-13 Thread Gustavo Mejia

Hi,


I am using Cocoon 1.8.2, and I am trying to run this query, but I don't
see any result

My code here :

?xml version=1.0?
?cocoon-process type=xsp?

xsp:page
  language=java
  xmlns:esql=http://www.apache.org/1999/SQL/v2;
  xmlns:xsp=http://www.apache.org/1999/XSP/Core;
  xmlns:request=http://www.apache.org/1999/XSP/Request;

  page title=SQL Search Results
  esql:execute-query
  esql:driveroracle.jdbc.driver.OracleDriver/esql:driver
  esql:dburljdbc:oracle:thin:@MyIP:MyPort:cta/esql:dburl
  esql:usernameuserID/esql:username
  esql:passwordPassword/esql:password

  esql:doc-elementempleados/esql:doc-element
  esql:row-elementregistro/esql:row-element

  esql:queryselect * from employee
 /esql:query
 /esql:execute-query
  /page
/xsp:page

What I got is:

oracle.jdbc.driver.OracleDriver jdbc:oracle:thin:@MyIP:MyPort:cta userID
Password empleados registro select * from employee

Could you help me ??

Thanks

Gustavo


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

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




Re: Problem with my query

2001-06-13 Thread Gustavo Mejia

Thanks,

I chanche my code to:
?xml version=1.0?

?cocoon-process type=xsp?
xsp:page
  xmlns:xsp=http://www.apache.org/1999/XSP/Core;
  xmlns:esql=http://apache.org/cocoon/SQL/v2;


page
esql:connection
  esql:driveroracle.jdbc.driver.OracleDriver/esql:driver
  esql:dburljdbc:oracle:thin:@MyIP:MyPort:cta/esql:dburl
  esql:usernameUserID/esql:username
  esql:passwordPassword/esql:password
  esql:execute-query
esql:queryselect * from employee/esql:query
esql:results
  headerheader info/header
  esql:row-results
empleado
  empnoesql:get-string column=empno//empno
  lastnameesql:get-string column=lastname//lastname
 /empleado 
  /esql:row-results
  footerfooter info/footer
/esql:results
  /esql:execute-query
/esql:connection
/page
/xsp:page

And now It works, but now what I wanto to do i to make variable the criteria of
my query, yes, something like

esql:queryselect * from employee where empno=MY_VARIABLE/esql:query

Do you know how can I do that ?

Thanks a lot !!

Gustavo


Luca Morandini wrote:

 Gustavo,

 have you already added something like this in cocoon.xconf (under the
 datasources tag) ?

 jdbc name=oracle
 pool-controller min=5 max=10 oradb=true/
 dburljdbc:oracle:thin:@localhost:1521:ORA81/dburl
 userlogin/user
 passwordpassword/password
 /jdbc

 Remember to re-start Tomcat afterwards any change to cocoon.xconf !

 Best regards,

 -
Luca Morandini
GIS Consultant
 [EMAIL PROTECTED]
   +39 (0)744  59 85  1 Office
   +39 0335 681 02 12 Mobile
 http://utenti.tripod.it/lmorandini/index.html
 -

  -Original Message-
  From: Gustavo Mejia [mailto:[EMAIL PROTECTED]]
  Sent: mercoledì 13 giugno 2001 16.16
  To: [EMAIL PROTECTED]
  Subject: Problem with my query
  Importance: High
 
 
  Hi,
 
 
  I am using Cocoon 1.8.2, and I am trying to run this query, but I don't
  see any result
 
  My code here :
 
  ?xml version=1.0?
  ?cocoon-process type=xsp?
 
  xsp:page
language=java
xmlns:esql=http://www.apache.org/1999/SQL/v2;
xmlns:xsp=http://www.apache.org/1999/XSP/Core;
xmlns:request=http://www.apache.org/1999/XSP/Request;
  
page title=SQL Search Results
esql:execute-query
esql:driveroracle.jdbc.driver.OracleDriver/esql:driver
esql:dburljdbc:oracle:thin:@MyIP:MyPort:cta/esql:dburl
esql:usernameuserID/esql:username
esql:passwordPassword/esql:password
 
esql:doc-elementempleados/esql:doc-element
esql:row-elementregistro/esql:row-element
 
esql:queryselect * from employee
   /esql:query
   /esql:execute-query
/page
  /xsp:page
 
  What I got is:
 
  oracle.jdbc.driver.OracleDriver jdbc:oracle:thin:@MyIP:MyPort:cta userID
  Password empleados registro select * from employee
 
  Could you help me ??
 
  Thanks
 
  Gustavo
 
 
  -
  Please check that your question has not already been answered in the
  FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 

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

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


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

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




Re: Apache + Tomcat 3.2.2+cocoon 1.8.2

2001-06-13 Thread Gustavo Mejia


I had the same problem, so I
modified the tomcat.bat, and also my Classpath, checking that all the classes
were in Tomcat_Home/lib
here is my Tomcat.bat.
set _CP=%CP%
set _TOMCAT_HOME=%TOMCAT_HOME%
set _CLASSPATH=%CLASSPATH%

rem - Verify and Set
Required Environment Variables -
if not "%JAVA_HOME%" == ""
goto gotJavaHome
echo You must set JAVA_HOME
to point at your Java Development Kit installation
goto cleanup
:gotJavaHome
if not "%TOMCAT_HOME%" ==
"" goto gotTomcatHome
set TOMCAT_HOME=.
:gotTomcatHome
if exist "%TOMCAT_HOME%\lib\servlet.jar"
goto okTomcatHome
echo Unable to locate servlet.jar,
check the value of TOMCAT_HOME.
goto cleanup
:okTomcatHome

rem - Prepare Appropriate
Java Execution Commands ---
if not "%OS%" == "Windows_NT"
goto noTitle
set _SECSTARTJAVA=start
"Secure Tomcat 3.2" "%JAVA_HOME%\bin\java"
set _STARTJAVA=start "Tomcat
3.2" "%JAVA_HOME%\bin\java"
set _RUNJAVA="%JAVA_HOME%\bin\java"
goto setClasspath
:noTitle
set _SECSTARTJAVA=start
"%JAVA_HOME%\bin\java"
set _STARTJAVA=start "%JAVA_HOME%\bin\java"
set _RUNJAVA="%JAVA_HOME%\bin\java"

rem - Set Up The Runtime
Classpath --
:setClasspath
set CP=%TOMCAT_HOME%\classes
rem Try to determine if TOMCAT_HOME
contains spaces
rem
if exist %TOMCAT_HOME%\lib\servlet.jar goto dynClasspath
echo Your TOMCAT_HOME appears
to contain spaces.
echo Unable to set CLASSPATH
dynamically.
goto staticClasspath
rem:dynClasspath
rem
set _LIBJARS=
rem
for %%i in (%TOMCAT_HOME%\lib\*.jar) do call %TOMCAT_HOME%\bin\cpappend.bat
%%i
rem
if not "%_LIBJARS%" == "" goto gotLibJars
rem
echo Unable to set CLASSPATH dynamically.
remif
"%OS%" == "Windows_NT" goto staticClasspath
rem
echo Note: To set the CLASSPATH dynamically on Win9x systems
rem
echo only DOS 8.3 names may be used
in TOMCAT_HOME!
rem
goto staticClasspath
rem
:gotLibJars
rem
echo Including all jars in %TOMCAT_HOME%\lib in your CLASSPATH.
rem
Note: _LIBJARS already contains a leading semicolon
rem
set CP=%CP%%_LIBJARS%
rem
goto chkClasspath
:staticClasspath
echo
Setting your CLASSPATH statically.
if
exist "%TOMCAT_HOME%\lib\axerces.jar" set CP=%CP%;%TOMCAT_HOME%\lib\axerces.jar
if
exist "%TOMCAT_HOME%\lib\zant.jar" set CP=%CP%;%TOMCAT_HOME%\lib\zant.jar
if
exist "%TOMCAT_HOME%\lib\jasper.jar" set CP=%CP%;%TOMCAT_HOME%\lib\jasper.jar
if
exist "%TOMCAT_HOME%\lib\jaxp.jar" set CP=%CP%;%TOMCAT_HOME%\lib\jaxp.jar
if
exist "%TOMCAT_HOME%\lib\parser.jar" set CP=%CP%;%TOMCAT_HOME%\lib\parser.jar
if
exist "%TOMCAT_HOME%\lib\servlet.jar" set CP=%CP%;%TOMCAT_HOME%\lib\servlet.jar
if
exist "%TOMCAT_HOME%\lib\webserver.jar" set CP=%CP%;%TOMCAT_HOME%\lib\webserver.jar
if
exist "%TOMCAT_HOME%\lib\cocoon.jar" set CP=%CP%;%TOMCAT_HOME%\lib\cocoon.jar
if
exist "%TOMCAT_HOME%\lib\fesi.jar" set CP=%CP%;%TOMCAT_HOME%\lib\fesi.jar
if
exist "%TOMCAT_HOME%\lib\sax-bugfix.jar" set CP=%CP%;%TOMCAT_HOME%\lib\sax-bugfix.jar
if
exist "%TOMCAT_HOME%\lib\w3c.jar" set CP=%CP%;%TOMCAT_HOME%\lib\w3x.jar
if
exist "%TOMCAT_HOME%\lib\xml.jar" set CP=%CP%;%TOMCAT_HOME%\lib\xml.jar
if
exist "%TOMCAT_HOME%\lib\xt.jar" set CP=%CP%;%TOMCAT_HOME%\lib\xt.jar
:chkClasspath
if "%CLASSPATH%" == "" goto
noClasspath
set CP=%CP%;%CLASSPATH%
:noClasspath
if not exist "%JAVA_HOME%\lib\tools.jar"
goto installClasspath
set CP=%CP%;%JAVA_HOME%\lib\tools.jar
:installClasspath
echo.
echo Using CLASSPATH: %CP%
echo.
set CLASSPATH=%CP%
rem - Execute The Requested
Command -
if "%1" == "start" goto startServer
if "%1" == "stop" goto stopServer
if "%1" == "run" goto runServer
if "%1" == "ant" goto runAnt
if "%1" == "env" goto doEnv
if "%1" == "jspc" goto runJspc
:doUsage
echo Usage: tomcat
( ant ^| env ^| jspc ^| run ^| start ^| stop )
echo Commands:
echo ant -
Run Ant in Tomcat's environment
echo env -
Set up environment variables that Tomcat would use
echo jspc -
Run JSPC in Tomcat's environment
echo run -
Start Tomcat in the current window
echo start -
Start Tomcat in a separate window
echo stop -
Stop Tomcat
goto cleanup
:doEnv
goto finish
:startServer
echo Starting Tomcat in
new window
if "%2" == "-security" goto
startSecure
%_STARTJAVA% %TOMCAT_OPTS%
-Dtomcat.home="%TOMCAT_HOME%" org.apache.tomcat.startup.Tomcat %2 %3 %4
%5 %6 %7 %8 %9
goto cleanup
:startSecure
echo Starting Tomcat with
a SecurityManager
%_SECSTARTJAVA% %TOMCAT_OPTS%
-Djava.security.manager -Djava.security.policy=="%TOMCAT_HOME%/conf/tomcat.policy"
-Dtomcat.home="%TOMCAT_HOME%" org.apache.tomcat.startup.Tomcat %3 %4 %5
%6 %7 %8 %9
goto cleanup
:runServer
rem Running Tomcat in this
window
if "%2" == "-security" goto
runSecure
%_RUNJAVA% %TOMCAT_OPTS%
-Dtomcat.home="%TOMCAT_HOME%" org.apache.tomcat.startup.Tomcat %2 %3 %4
%5 %6 %7 %8 %9
goto cleanup
:runSecure
rem Running Tomcat with
a SecurityManager
%_RUNJAVA% %TOMCAT_OPTS%
-Djava.security.manager -Djava.security.policy=="%TOMCAT_HOME%/conf/tomcat.policy"
-Dtomcat.home="%TOMCAT_HOME%" 

Re: Problem with my query

2001-06-13 Thread Gustavo Mejia

Thanks Christopher,

But now, how can I assign the variable from other XML, how can I pass to
the XML with my query ?

I really apreciate your hellp !

Gustavo


Christopher Painter-Wakefield wrote:

 Gustavo,

 try this:

 esql:queryselect * from employee where empno=
   esql:parameterMY_VARIABLE/esql:parameter
 /esql:query

 You may need to specify a type, such as esql:parameter type=int,
 otherwise it will assume a String.

 -Christopher

 Thanks,

 I chanche my code to:
 ?xml version=1.0?

 ?cocoon-process type=xsp?
 xsp:page
   xmlns:xsp=http://www.apache.org/1999/XSP/Core;
   xmlns:esql=http://apache.org/cocoon/SQL/v2;
 

 page
 esql:connection
   esql:driveroracle.jdbc.driver.OracleDriver/esql:driver
   esql:dburljdbc:oracle:thin:@MyIP:MyPort:cta/esql:dburl
   esql:usernameUserID/esql:username
   esql:passwordPassword/esql:password
   esql:execute-query
 esql:queryselect * from employee/esql:query
 esql:results
   headerheader info/header
   esql:row-results
 empleado
   empnoesql:get-string column=empno//empno
   lastnameesql:get-string column=lastname//lastname
  /empleado 
   /esql:row-results
   footerfooter info/footer
 /esql:results
   /esql:execute-query
 /esql:connection
 /page
 /xsp:page

 And now It works, but now what I wanto to do i to make variable the
 criteria of
 my query, yes, something like

 esql:queryselect * from employee where empno=MY_VARIABLE/esql:query

 Do you know how can I do that ?

 Thanks a lot !!

 Gustavo

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

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


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

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




Re: Problem with my query

2001-06-13 Thread Gustavo Mejia

Thanks again,

Right, I need to do the first thing that you told me, I tried but with no
results, I have something like this:

esql:queryselect * from employee
where empno=esql:parameterVAR/esql:parameter
/esql:query

and in my browser the url is:

http://localhost/cocoon/servlet/sql/esql.xml?VAR=01;

but, doesn't show information.

Maybe it is not very difficult, but I really starting with this things.

Thanks

Gustavo


Christopher Painter-Wakefield wrote:

 Gustavo,

 you're welcome.  There are probably many ways to do what you are asking;
 you should probably get a book on servlet programming or web application
 development.  Anything that you can do with CGI or servlets you can do (I
 believe) with XSP and Cocoon.  So, for instance, you can pass parameters in
 the query string (http://myserver.org/cocoon/myquery.xml?empno=1234), or
 you can store stuff in the session, or you can store stuff in a database,
 etc.  Is there a specific approach you wanted to ask about?

 -Christopher

 Thanks Christopher,

 But now, how can I assign the variable from other XML, how can I pass to
 the XML with my query ?

 I really apreciate your hellp !

 Gustavo

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

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


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

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




Formating !

2001-06-12 Thread Gustavo Mejia


Hi,
I am here again, I already
got to use a XSL with my query, but I change my previous SQL to ESQL, and
I got some errors, could you tell me what's wrong ?
Here my code:
?xml version="1.0"?>
?cocoon-process type="xsp"?>
?xml-logicsheet href="resource://org/apache/cocoon/processor/xsp/library/sql/esql.xsl"?>
?xml-stylesheet href="taglib.xsl"
type="text/xsl"?>
?cocoon-process type="xslt"?>
xsp:page
 language="java"
 xmlns:esql="http://www.apache.org/1999/SQL/v2"
 xmlns:xsp="http://www.apache.org/1999/XSP/Core"
 xmlns:request="http://www.apache.org/1999/XSP/Request"
>
 page title="SQL
Search Results">
 esql:execute-query>
 esql:driver>oracle.jdbc.driver.OracleDriver/esql:driver>
 esql:dburl>jdbc:oracle:thin:@204.153.24.233:1521:cta/esql:dburl>
 esql:username>myuser/esql:username>
 esql:password>mypassword/esql:password>
 esql:doc-element>empleados/esql:doc-element>
 esql:row-element>registro/esql:row-element>

 esql:query>select
* from employee/esql:query>
/esql:execute-query>
 /page>
/xsp:page>
The errors that I got
are :
Error found handling the
request.
java.lang.Exception: XSP
Java Compiler: Compilation failed for _taglib.java
82: Duplicate variable declaration:
DBBroker _esql_pool was DBBroker _esql_pool
 static DBBroker
_esql_pool = DBBroker.getInstance();

^
83: Class _C_._tomcat._webapps._cocoon._servlets._sql._taglib.
EsqlSession already defined in C:\tomcat\bin\repository\_C_\_tomcat\_webapps\_cocoon\_servlets\_sql\_taglib.java.

class EsqlSession {

^
83: Duplicate inner class
declaration: nested type _C_._tomcat._webapps._cocoon._servlets._sql._taglib.
EsqlSession is already defined in this scope.

class EsqlSession {

^
3 errors
at org.apache.cocoon.processor.xsp.language.java.XSPJavaProcessor.compile(XSPJavaProcessor.java:141)
at org.apache.cocoon.processor.xsp.XSPProcessor.process(XSPProcessor.java:489)
at org.apache.cocoon.Engine.handle(Engine.java:359)
at org.apache.cocoon.Cocoon.service(Cocoon.java:167)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:404)
at org.apache.tomcat.core.Handler.service(Handler.java:286)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java:210)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:498)
at java.lang.Thread.run(Thread.java:484)
Thanks a lot,
Gustavo Mejia
INFOTEC


JEULIN Olivier wrote:
Hi,
WARNING: you are using a deprecated taglib! The correct one is esql,
not
sql.
Take a look at your cocoon/samples/sql for a sample.
You will find the available elements in esql.xsd in the same directory.
Olivier
> -Message d'origine-
> De : Gustavo Mejia [mailto:[EMAIL PROTECTED]]
> Envoy : lundi 11 juin 2001 20:29
>  : [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Objet : Formating !
> Importance : Haute
>
>
> > Hi,
> >
> > I am new using cocoon, I am get results using a query, and
> now I wan format that information, could you
> > tell how can I do that ? I know that I need XSL document, I
> already try with this, and I did't get it.
> > here my code ..
> >
> > ?xml version="1.0"?>
> > ?cocoon-process type="xsp"?>
> >
> > xsp:page
> > language="java"
> > xmlns:sql="http://www.apache.org/1999/SQL"
> > xmlns:xsp="http://www.apache.org/1999/XSP/Core"
> > xmlns:request="http://www.apache.org/1999/XSP/Request"
> > >
> >
> > page title="SQL Search Results">
> >
> > sql:execute-query>
> > sql:driver>oracle.jdbc.driver.OracleDriver/sql:driver>
> > sql:dburl>jdbc:oracle:thin:@host:1521:CTA/sql:dburl>
> > sql:username>mypassword/sql:username>
> > sql:password>myuser/sql:password>
> > sql:doc-element>empleados/sql:doc-element>
> > sql:row-element>registro/sql:row-element>
> >
> > sql:query>select
* from employee order by empno/sql:query>
> > /sql:execute-query>
> > /page>
> > /xsp:page>
> >
> > Thanks in advance !
> > Gustavo Mejia
> > www.Infotec.com.mx
>
>
> -
> Please check that your question has not already been answered in
the
> FAQ before posting. http://xml.apache.org/cocoon/faqs.html>
>
> To unsubscribe, e-mail: [EMAIL PROTECTED]>
> For additional commands, e-mail: [EMAIL PROTECTED]>
>
-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html>
To unsubscribe, e-mail: [EMAIL PROTECTED]>
For additional commands, e-mail: [EMAIL PROTECTED]>