public static int check(String name, String email, String password) throws SQLException {
return statement.executeUpdate(String.format("""
SELECT name, email, password FROM userlogins
WHERE name = '%s' AND email = '%s' AND password = '%s'
""", name, email, password));
}
public static boolean check(String name, String email, String password) throws SQLException {
ResultSet resultSet = statement.executeQuery(String.format("""
SELECT count(*) as cnt FROM userlogins
WHERE name = '%s' AND email = '%s' AND password = '%s'
""", name, email, password));
resultSet.next();
return resultSet.getBoolean(1);