Besides the String concats being wrong (may not effect error ur getting but will effect resulting page)

From javadocs on resultset

Column names used as input to getXXX methods are case insensitive. When a getXXX method is called with a column name and several columns have the same name, the value of the first matching column will be returned. The column name option is designed to be used when column names are used in the SQL query that generated the result set. For columns that are NOT explicitly named in the query, it is best to use column numbers. If column names are used, there is no way for the programmer to guarantee that they actually refer to the intended columns.

First try changing the getxxx methods to use column numbers and see if that works.

Then check ur cases and column names and try again.

If that doesnt work then please post the exact errormsg and and code that relates to that particular error msg.

-Tim

-----Original Message-----
From: Wasala Mudiyanselage Nilantha Piyasiri [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 04, 2002 5:49 PM
To: [EMAIL PROTECTED]
Subject: Re: Servlet - Value of a checkbox

It gives a message errorNo data found. But when I give a name to the value. The servlet is working. Is there any way I cant give the rs.getString (data) to the value.
----- Original Message -----
Sent: Friday, January 04, 2002 12:22 AM
Subject: Re: Servlet - Value of a checkbox

what exactly happens when u say it isn ot working ?
    any exception ??
    kindly let us know  so that we can suggest
-----Original Message-----
From: Wasala Mudiyanselage Nilantha Piyasiri [mailto:[EMAIL PROTECTED]]
Sent: Saturday, January 05, 2002 3:53 AM
To: [EMAIL PROTECTED]
Subject: Servlet - Value of a checkbox

Dear All,
 
Following line is not working. Could I use rs.getSrting to give the value to checkbox. Please help me
 
out.println ("<tr><td><input type=checkbox name=item" + "value="+rs.getString ("book")+"></td><td>"+rs.getString ("ID")+"</td><td>"+rs.getString ("book")+"</td><td>"+rs.getDouble("price")+"</td></tr>");
 
 
Regards,
 
Nilantha

Reply via email to