개인적인 정리

Parameter index out of range (1 > number of parameters, which is 0). 본문

전자정부표준프레임워크/Exception 및 Error

Parameter index out of range (1 > number of parameters, which is 0).

yeon.Biju 2018. 12. 6. 11:29

 

Parameter index out of range (1 > number of parameters, which is 0).

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1073)

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:987)

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:982)

at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:927)

at com.mysql.jdbc.PreparedStatement.checkBounds(PreparedStatement.java:3717)

at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3701)

at com.mysql.jdbc.PreparedStatement.setString(PreparedStatement.java:4541)

at core.log.impl.PreparedStatementLoggable.setString(PreparedStatementLoggable.java:165)

at sun.reflect.GeneratedMethodAccessor76.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

 

...

 

오류 발생

 

INSERT 

    INTO

        테이블명

        (      ......  )

    VALUES

        {      ?/**P*/,      ?/**P*/,      ?/**P*/,      ?/**P*/,      ?/**P*/,      'N',      now(),      now(),      ?/**P*/     }

 

 

VALUES 뒤에 () 가 아닌 {} 여서 발생.

 

 

 

Comments