我要存储六个变量,其中三个是整数,三个是字符串数据类型,这是我准备好的语句代码
PreparedStatement stmt = connection.prepareStatement("insert into mydb (firstInt, firstString, secondString, secondInt, thirdInt, thirdString ) values (?, ?, ?, ?, ?, ?)");
stmt.setInt(1, firstInt);
stmt.setString(2, firstString);
stmt.setString(3, secondString);
stmt.setInt(4, secondInt);
stmt.setInt(5, thirdInt);
stmt.setString(6, thirdString);
stmt.executeUpdate();
问题是字符串和整数类型变量没有存储在数据库中。这段代码有什么问题?