This commit is contained in:
2023-07-02 11:19:15 +08:00
parent 6831164da8
commit 818ffd8ffe

View File

@@ -106,7 +106,7 @@ public class projectDao {
try {
Connection conn = JdbcUtils.getConnection();
QueryRunner runner = new QueryRunner();
String sql = "select * from project where projectId in (select projectId from project_category where category in(select categoryId from categoty where categoryName = ?))";
String sql = "select * from project where projectId in (select projectId from project_category where categoryId in(select categoryId from category where categoryName = ?))";
projectEntityList = runner.query(conn, sql, new BeanListHandler<>(projectEntity.class),name);
conn.close();
} catch (SQLException e) {
@@ -120,7 +120,7 @@ public class projectDao {
try {
Connection conn = JdbcUtils.getConnection();
QueryRunner runner = new QueryRunner();
String sql = "select * from project where projectId in (select projectId from project_category where categoryId in(select categoryId from categoty where categoryName = ?)) order by lookCount desc";
String sql = "select * from project where projectId in (select projectId from project_category where categoryId in(select categoryId from category where categoryName = ?)) order by lookCount desc";
projectEntityList = runner.query(conn, sql, new BeanListHandler<>(projectEntity.class),name);
conn.close();
} catch (SQLException e) {