Answer the question
In order to leave comments, you need to log in
How to check if a record is present in a table?
There is a code:
Connection c = DriverManager.getConnection(road);
if(!c.createStatment().executeQuery("SELECT * FROM users WHERE name = 'name'").isBeforeFirst()){
//TODO...
return;
}
if(c.createStatment().executeQuery("SELECT * FROM users WHERE name = 'name'").getString("address") == "0.0.0.0"){
//TODO...
return;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question