【文件属性】:
文件名称:Day 37 JDBC高级
文件大小:102KB
文件格式:PDF
更新时间:2021-01-21 16:54:23
jdbc resultset string
JDBC高级
1. Statement操作SQL语句
1.1 Statement查询SQL数据操作
// 查询指定的一个数据行,转换成对应的User对象
@Test
public void testSelectOne() {
ResultSet resultSet = null;
Statement statement = null;
Connection connection = null;
User user1 = null;
try {
// 1. 加载驱动
Class.forName(com.mysql.jdbc