1

i have one parameter that i am passing from a JSP using Ajax which is:

keyword_name;

i have tested to see if their was something in the parameter, their was:

apple

the code below is my ResultSet:

ResultSet rs = stmt.executeQuery("Select keyword_name from keywords                   where keyword_name="+keyword_name+""); 

and the below is the printing of the result set:

while(rs.next()){
buffer=buffer+"<tr><td>"+rs.getString("keyword_name")+"</td></tr>";  
}

Full ERROR code:

java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1. 

Any ideas!!

4

1 に答える 1

1

そんなはずないでしょ

<..> where keyword_name='"+keyword_name+"'"
于 2012-04-23T20:58:10.980 に答える