Closed looly closed 4 months ago
Describe the bug
When I use JDBC to build a PreparedStatement and use setObject method to insert to database, a String value can insert to a Integer column.
PreparedStatement
setObject
To Reproduce
I use Hutool wrap the sql and insert to db.
final Db db = Db.of(DbConfig.of().setUrl("jdbc:sqlite:d:/test/test.db")); db.insert(Entity.of("user").set("age", "testStr2"));
and age column is a INTEGER column.
age
Expected behavior A clear and concise description of what you expected to happen.
Logs
Environment (please complete the following information):
Additional context
SQLite doesn't care about types.
Describe the bug
When I use JDBC to build a
PreparedStatement
and usesetObject
method to insert to database, a String value can insert to a Integer column.To Reproduce
I use Hutool wrap the sql and insert to db.
and
age
column is a INTEGER column.Expected behavior A clear and concise description of what you expected to happen.
Logs
Environment (please complete the following information):
Additional context