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>
mvh: Pål Wester
</esql:connection>
}
</xsp:logic>
høgskoleingenør/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