/**
* jdbc 查询语句 Student类省略
*/
import Day01.Text03.Student;
import java.sql.*;
public class Deom {
public static void main(String[] args) {
Connection conn = null;
Statement statement = null;
ResultSet resultSet = null;
try {
/**
* 注册驱动
*/
Class.forName("com.mysql.jdbc.Driver");
/**
* 获得数据库连接对象
*/
conn = DriverManager.getConnection("jdbc:mysql:///my_db", "root", "hao");
/**
jdbc 查询语句
最新推荐文章于 2023-10-03 23:05:11 发布