I would like a table, when I want it to increase again from 1, but I searched in many places and this can not be done from java ... although if someone knows it would be great, if they could help me. Then going back to the topic, as an alternative to this, they advise creating a table with the same fields and eliminating the other one. but you do not want to create the table from neatbeans. this error comes out As you can see it says that there is a parenthesis that does not wait but I have reviewed my parentheses and they are fine ... I could collaborate and see where the error is please.
try {
String name="ticket2";
String Query = "CREATE TABLE " + name + ""
+ "(id int(10) not null auto_increment,primary key (id),cod VARCHAR(50), nombre VARCHAR(50),kilox VARCHAR(50), precio VARCHAR(50),peso VARCHAR(50),total VARCHAR(50))";
connection=con.conexion();
ps=connection.prepareStatement(Query);
ps.execute();
ps.close();
}catch (SQLException e){
JOptionPane.showMessageDialog(null,"Error al eliminar producto de venta,Error de sistema, comuniquese con proveedor: "+e);
}