tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Weßling, Achim" <>
Subject validation problem in JSP
Date Thu, 22 Mar 2001 15:53:40 GMT

I did the following code. My problem is marked with '*'. How can I validate
the value of <infokomGT:rowCount/> (jdbc:rowCount) with '1' so that my
condition-tag gets the body-value 'true' or 'false'?

<%@page contentType="text/html"%>
<%@ taglib uri="/infokomGT" prefix="infokomGT" %>
<head><title>User Validation</title></head>
<br>Diese Werte wurden eingegeben:
Benutzername: <infokomGT:parameter name="user" />
Passwort: <infokomGT:parameter name="pw" />
<%-- Open Database Connection --%>
<infokomGT:connection id="con1">
<%-- Open Database --%>
<infokomGT:statement id="stmt1" conn="con1">
        SELECT FirstName, LastName, Anrede, Typ
        FROM User
        WHERE UserName LIKE '<infokomGT:parameter name="user" />'
        AND Kennwort LIKE '<infokomGT:parameter name="pw" />'
    <%-- loop through the rows of query --%>
    <infokomGT:resultSet id="rs1">
            <infokomGT:condition><%= <infokomGT:rowCount/> == 1
                <br>Allright, you did it!
        <br>Sorry, but you did something wrong!

<%-- close Database Connection --%>
<infokomGT:closeConnection conn="con1"/>

Mit freundlichem Gruß

Achim Weßling

INFOKOM Gütersloh
Fachbereich Technische Anwendungen / Zentrale Anwendungen
Tel.: 05241/85-2926

                  (o o)

View raw message