Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > JSP Basics
|
JSP Basics Beginning-level questions on JSP. More advanced coders should post to Pro JSP.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the JSP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 14th, 2004, 08:07 AM
Authorized User
 
Join Date: Oct 2004
Posts: 34
Thanks: 0
Thanked 0 Times in 0 Posts
Default updation prob..........

i have an jsp page which is used to update the two tables named
1) pay_header 2) pay_detail.

In which the values of chq_amt of table 1 should be equal to values of db_amt of table 2.

i have used the following query:

PreparedStatement pstatement = conn.prepareStatement(
"UPDATE pay_header,pay_detail SET pay_header.chq_amt=pay_detail.db_amt where pay_header.vou_no = pay_detail.vou_no");


pstatement.setFloat(1,Float.parseFloat(request.get Parameter("chq_amt")));
pstatement.setFloat(2,Float.parseFloat(request.get Parameter("db_amt")));
pstatement.setString(3,request.getParameter("vou_n o"));

int rowCount = pstatement.executeUpdate();
conn.setAutoCommit(false);
conn.setAutoCommit(true);


its coming error

help







Similar Threads
Thread Thread Starter Forum Replies Last Post
help in updation sanjeev jha Classic ASP Basics 0 November 12th, 2007 04:17 AM
updation prob.......... abhit_kumar MySQL 0 December 14th, 2004 08:06 AM
Problem in updation abhit_kumar JSP Basics 3 November 30th, 2004 09:47 AM
updation problem abhit_kumar Pro JSP 0 November 25th, 2004 01:44 AM
updation of datasource abhimca_1 ADO.NET 0 August 5th, 2003 07:23 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.