Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- INSERT new row into database java?
- try {
- Main.db.getCon().createStatement().executeUpdate("INSERT INTO qos_qoe (channel_id) VALUES ('vtv1') ");
- Main.db.getCon().createStatement().executeUpdate("UPDATE qos_qoe SET channel_id = 'vtv1' WHERE id = 3 ");
- } catch (SQLException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- String statement = "UPDATE iptv_media_source SET rated = ?, vote_count = ? WHERE channel_id= ? ";
- PreparedStatement st = Main.db.getCon().prepareStatement(statement);
- st.setString(1, rated);
- st.setString(2, vote_count);
- st.setString(3, channelId);
- st.executeUpdate();
Add Comment
Please, Sign In to add comment