2023年11月3日
摘要: 动态sql 因为会出现三个条件只填其中一个或两个进行查询的情况,所以要使用动态sql语句进行查询 1、使用if进行条件判断,test:逻辑表达式 <select id="selectByid" resultType="brand"> select * from tb_brand where id = 阅读全文
posted @ 2023-11-03 19:46 na2co3- 阅读(181) 评论(0) 推荐(0)
摘要: 执行方法 @Test public void testSelectBycondition() throws IOException { //接收变量 int status = 0; String company_name = "华为"; String brand_name = "华为"; //处理数 阅读全文
posted @ 2023-11-03 10:07 na2co3- 阅读(81) 评论(0) 推荐(0)