cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vadim Gritsenko" <vgritse...@hns.com>
Subject RE: How can I make a validation !
Date Mon, 18 Jun 2001 20:39:04 GMT
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:gmejia@infotec.com.mx]
  Sent: Monday, June 18, 2001 15:03
  To: cocoon-users@xml.apache.org
  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



Mime
View raw message