I have String array like
String[] val=request.getParameterValues("Names");  
for(int i=0;i<val.length;i++){  
 //printval[i];
}
I would like to assign the values of String array to a sql statement as
How can I pass all the string values to sql condition? If array have the following values
JAMES,SMITH, JAKE etc, then I would pass it as 
sql =  "where dept_name in('JAMES','SMITH','JAKE')"; 
Ideally I would want the string array values to be passed inside the in condition of sql.
 
     
     
     
     
    