select1 cannot be resolved

Help me detect the error mentioned in subject: It gives error on every line where select1 is used.

The syntax is correct as much as i know but it is not able to create the select statement and not able to execute the select query

Brijesh Shah

<%@ page language="java" info="AMSX Submit Audit Page" %>

<HTML>

<HEAD><TITLE>AMSX</TITLE></HEAD>

<BODY BGCOLOR="#FDF5E6">

<H1>Asset Management System (AMSX) </H1>

<x:driverManagerSpec id="conn1" driver="com.microsoft.jdbc.sqlserver.SQLServerDriver"

url="jdbc:microsoft:sqlserver://10.187.33.159:49408/AMSX"

userid='<%= request.getParameter("userid") %>'

password='<%= request.getParameter("password") %>' />

<x:select id="select1" scope="session" connectionSpec="conn1">

<%-- Set the parameter using the input value from the HTML page --%>

<x:sql>

SELECT ap_WorkforceID, ap_FullName, ap_PersonOUC FROM t_amsx_people WHERE ap_WorkforceID = '802018661'

</x:sql>

<%-- x:parameter parmName="DEPT" type="SMALLINT"

value='<%= request.getParameter("deptnumber") %>' / --%>

</x:select>

<form method="POST" action="ChangeByRow.jsp">

<h3>Employee Number <%= request.getParameter("EIN") %></h3>

<%-- This hidden input field is used to pass the department number along to the --%>

<%-- JSP that processes this form. --%>

<%-- INPUT type="hidden" name="ap_WorkforceID" value='<%= request.getParameter("EIN") %>' / --%>

<h3>Row <%=select1.getRow() %> of <%=select1.getRowCount() %> </h3>

<%-- Only display values if result set is not empty --%>

<% if (select1.first()) { %>

<table border="1"><tbody>

<tr>

<td>Employee Number:</td>

<td><INPUT size="40" type="text" name="ap_WorkforceID"

value='<x:getColumn name="select1" colName="ap_WorkforceID" />'>

</td>

</tr>

<tr>

<td>Employee Name:</td>

<td><INPUT size="40" type="text" name="ap_FullName"

value='<x:getColumn name="select1" colName="ap_FullName" />'>

</td>

</tr>

<tr>

<td>Employee OUC:</td>

<td><INPUT size="40" type="text" name="ap_PersonOUC"

value='<x:getColumn name="select1" colName="ap_PersonOUC" />'>

</td>

</tr>

</tbody></table>

<INPUT type="submit" name="previous" value="Previous row">

<INPUT type="submit" name="next" value="Next row">

<INPUT type="submit" name="update" value="Update row">

<INPUT type="submit" name="delete" value="Delete row">

<INPUT type="submit" name="insert" value="Insert another row">

<% } %>

</form>

</BODY>

</HTML>

[2905 byte] By [BrijeshShaha] at [2007-11-27 11:25:50]
# 1

The goggles! They do nothing!

Please repost that with some sane formatting. Line breaks and [code][/code] tags.

hunter9000a at 2007-7-29 16:06:51 > top of Java-index,Java Essentials,New To Java...
# 2

> Please repost that with some sane formatting.

SQL scriptlets in a JSP? I'm not sure sane formatting is going to make me any more excited about looking at it... :o)

yawmarka at 2007-7-29 16:06:51 > top of Java-index,Java Essentials,New To Java...
# 3

> The goggles! They do nothing!

>

Simpsons references rock :)

macrules2a at 2007-7-29 16:06:51 > top of Java-index,Java Essentials,New To Java...