이 쿼리문에서


err : com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '? and name = ?' at line 1


이런 오류가 발생하거든?

이게, name이 문자열이라서 따옴표 처리를 해줘야 하는것 같아서 뒷 부분을 name = '?' "; 이렇게 처리를하니까


err : java.sql.SQLException: Parameter index out of range (2 > number of parameters, which is 1).


이런 오류가 발생한다...

where절 조건을 쿼리문으로 주고싶은데, 어떻게 해야하는지 가르쳐줄 갤러..? ㅠㅠ