摘要: ![](https://img2024.cnblogs.com/blog/3516303/202409/3516303-20240910201615415-2005593885.png) ![](https://img2024.cnblogs.com/blog/3516303/202409/3516303-20240910201716935-1431992489.png) ![](https:// 阅读全文
posted @ 2024-09-10 20:18 wangyin0425 阅读(2) 评论(0) 推荐(0) 编辑
摘要: ![](https://img2024.cnblogs.com/blog/3516303/202409/3516303-20240910112224391-2061676106.png) ![](https://img2024.cnblogs.com/blog/3516303/202409/3516303-20240910112703710-337718418.png) ![](https://i 阅读全文
posted @ 2024-09-10 11:37 wangyin0425 阅读(2) 评论(0) 推荐(0) 编辑
摘要: package PRACTICE; import DUIXIANG.Brand; import com.alibaba.druid.pool.DruidDataSourceFactory; import javax.sql.DataSource; import java.io.FileInputSt 阅读全文
posted @ 2024-09-10 11:09 wangyin0425 阅读(5) 评论(0) 推荐(0) 编辑
摘要: package DRUID; import com.alibaba.druid.pool.DruidDataSourceFactory; import javax.sql.DataSource; import java.io.FileInputStream; import java.sql.Conn 阅读全文
posted @ 2024-09-09 18:22 wangyin0425 阅读(3) 评论(0) 推荐(0) 编辑
摘要: package DUIXIANG; public class Account { private int id; private String name; private Double money; public int getId(){ return this.id; } public void 阅读全文
posted @ 2024-09-09 11:46 wangyin0425 阅读(7) 评论(0) 推荐(0) 编辑
摘要: package JDBC; import java.sql.*; public class JDBCDemo { public static void main(String[] args) throws Exception { //1.注册驱动 Class.forName("com.mysql.c 阅读全文
posted @ 2024-09-09 08:42 wangyin0425 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 注意在当前窗口是修改了的: 而在其他窗口是不修改的: select @@autocommit; 修改为手动提交: 阅读全文
posted @ 2024-09-08 21:48 wangyin0425 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 数据准备 DROP TABLE IF EXISTS emp; DROP TABLE IF EXISTS dept; DROP TABLE IF EXISTS job; DROP TABLE IF EXISTS salarygrade; -- 部门表 CREATE TABLE dept ( id IN 阅读全文
posted @ 2024-09-08 21:19 wangyin0425 阅读(4) 评论(0) 推荐(0) 编辑
摘要: select * from emp where salary > (select salary from emp where name='猪八戒'); 1. select * from emp where dep_id in (select did from dept where dname in 阅读全文
posted @ 2024-09-08 18:12 wangyin0425 阅读(3) 评论(0) 推荐(0) 编辑
摘要: select emp.name,emp.gender,dept.dname from emp,dept where emp.dep_id=dept.did; select t1.name,t1.gender,t2.dname from emp t1,dept t2 where t1.dep_id=t 阅读全文
posted @ 2024-09-08 16:43 wangyin0425 阅读(6) 评论(0) 推荐(0) 编辑