开发者

after submiting form data it show's the following problem

开发者 https://www.devze.com 2022-12-11 02:04 出处:网络
An Exception has occurred! com.microso开发者_高级运维ft.sqlserver.jdbc.SQLServerException: The value is not set for the parameter number 1.You have a PreparedStatement with at least one valueholder ?.

An Exception has occurred! com.microso开发者_高级运维ft.sqlserver.jdbc.SQLServerException: The value is not set for the parameter number 1.


You have a PreparedStatement with at least one valueholder ?. When you execute it without having set the valueholder with a value using one of the PreparedStatement's setter methods, then you will get this exception. To solve this you obviously need to set the value with the desired value, e.g.

preparedStatement.setString(1, value);

Or if you don't need it at all, then just remove it from the SQL string or create another one for this specific purpose.

For more about PreparedStatements, consult the JDBC tutorial.

0

精彩评论

暂无评论...
验证码 换一张
取 消