I am trying to have this code run and delete a certain record in a MySQL database but I get this error:
SQLException: Can not issue data manipulation stateme
You use executeUpdate() for that instead.
executeUpdate()
executeQuery() is only for statements that return data. executeUpdate is for ones that won't return date (update, insert, delete, and I believe things like adding/dropping tables, constraints, triggers, and the like as well).
executeQuery()
executeUpdate