Java Sql Select MySQL Server JDBC Tutorial

In this java sql tutorial, we will select users table from MySQL Server using java code sample below.

Java SQL Select Code

Connection mycon = null;
Statement mystatment = null;

mystatment = mycon.createStatement();

ResultSet myrset = null;

myrset = mystatment.executeQuery("SELECT * FROM tbl_users");

This java code example, will return users table rows from MySQL Server.