wood burning stoves 2.0*
The moose likes JDBC and the fly likes Request.getParameterValues related question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Request.getParameterValues related question" Watch "Request.getParameterValues related question" New topic
Author

Request.getParameterValues related question

Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732


Thanks in anticipation
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9293
    
  17

Do you have any question?? The setString method doesn't take a String[]. That's why you are getting an error...


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732
Thanks for your prompt reply
Ankit Garg wrote:Do you have any question?? The setString method doesn't take a String[]. That's why you are getting an error...


This is my Questions as to how can I find the way to pass array in setString method. I tried with loop but not works. Can you guide me please

Thanks again
Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732
any help please
Jack Anderson
Greenhorn

Joined: Dec 19, 2009
Posts: 5
Hi Farakh,

The way i understand you problem is that you want to execute this query for each of the array objects.

If that is the case, you may write a very simple code like this:


Farakh khan
Ranch Hand

Joined: Mar 22, 2008
Posts: 732
My table structure & Query:


When am running Oracle SQL statement then its giving accurate results as I copy pasted above but when am running in servlet then it displays:

cv_id=1
cv_id=1
cv_id=21
cv_id=1
cv_id=21
cv_id=1
cv_id=21

Please note: cv_id is emp_id and this should be unique according to my SQL query but not getting the required results. Here is my code


I need output:

cv_id=1
cv_id=21

Where I am making mistake? Please help me to fix this problem

Thanks & best regards
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Request.getParameterValues related question