您现在的位置是:首页 > java技术交流java技术交流
mybatis plus3.3.2配置打印sql
上善若水2020-06-30 16:47:10【java技术交流】 3322人已围观
简介如何配置mybatis plus配置打印sql,控制台输出配置显示sql语句进行调试程序如何配置,如何配置mybatis,实测使用mybatis-plus-boot-starter3.3.2成功打印.
如何配置mybatis plus配置打印sql,控制台输出配置显示sql语句进行调试程序如何配置,如何配置mybatis,实测使用mybatis-plus-boot-starter3.3.2成功打印.
解决方案
如果是application.yml
#mybatis-plus配置控制台打印完整带参数SQL语句
mybatis-plus:
configuration:
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
如果是application.properties,添加
#mybatis-plus配置控制台打印完整带参数SQL语句
mybatis-plus.configuration.log-impl=org.apache.ibatis.logging.stdout.StdOutImpl
输出效果
Creating a new SqlSession
SqlSession [org.apache.ibatis.session.defaults.DefaultSqlSession@70721c12] was not registered for synchronization because synchronization is not active
JDBC Connection [com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl@388d14e] will not be managed by Spring
==> Preparing: SELECT id,category_id,cover,title,introduction,content,top,recommend,hot,browse,up,create_time,update_time FROM article
==> Parameters:
<== Columns: id, category_id, cover, title, introduction, content, top, recommend, hot, browse, up, create_time, update_time
<== Row: 1, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, thymeleaf中th:text和th:utext的区别, thymeleaf中th:text和th:utext的区别, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 2, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, 【Thymeleaf】格式化日期, 【Thymeleaf】格式化日期, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 3, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 4, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 5, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 6, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 7, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 8, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 9, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 10, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 11, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 12, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 13, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 14, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 15, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 16, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 17, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 18, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 19, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 20, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 21, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 22, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 23, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 24, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 25, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 26, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 27, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 28, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 29, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 30, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 31, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 32, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 33, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 34, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 35, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 36, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 37, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 38, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 39, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 40, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 41, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 42, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 43, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 44, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 45, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 46, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 47, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 48, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 49, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 50, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 51, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 52, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 53, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 54, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Row: 55, 1, https://p5.gexing.com/GSF/shaitu/20180318/1157/5aade3c1302d2.jpg, Spring Boot 2.2.7, Spring Boot 2.2.7, <<BLOB>>, 0, 0, 0, 1, 0, 2020-05-06 14:39:06, 2020-05-06 14:39:10
<== Total: 55
Tags: mybatis plus
很赞哦! (7)
相关文章
随机图文
-
2020.09.06武汉植物园,湖北艺术馆游玩
一天预约了两个景点一次玩个够,首先是武汉植物园,这里平时门票是需要35RMB呢,之前玩的景点都没排队,这个去的时候居然在排队,或许是我去的太早了吧,当时也就快1点的样子,是刷身份证进去的,整体整个植物 -
幽默笑话
1、儿子拿着一张破纸,对我说:“爸爸,我有一张藏宝图,我送给你,你给我10块钱好吗?”我拿过来一看,说道:“你这不就是画的咱家吗,怎么就叫藏宝图了,还给我要10块钱。”儿子:“爸爸,你看看用红笔画的地方.”我仔细一看,沙发底下,桌子腿底下……我靠,这逼崽子,这可是老子藏私房钱的地方,我赶紧跟儿子说:“那啥,宝贝儿,我给你50块!”2、师父手拿秘籍,一边读秘籍上的内容一边比划:“ -
幽默笑话:经理 贵宾房唱歌的妹子们都跑掉了
1.当年去媳妇家相亲,她爸问我:有车有房吗?”我说:叔叔,现在还没有,不过在不久的将来肯定会有,我不想用父母的钱享受,这些东西必须用自己的努力去得到才能踏实!”后来媳妇跟我说,她爸看中了我脸皮厚,虽然穷,道理说的好2.按照新学校的要求,转校学生必须填写“转学自评表”。在“曾经是否因为考试作弊受到处分”一栏,他填了一字“未”。下面一栏是“说明原因”,他继续写到:“未曾失手”。3.一大学生去爬 -
笑话6则:其实哄女孩子开心很简单
1、进药店想买TT,店里人太多不好意思,就对营业员说:“我买那个...”营业员说:“你买什么?”我支唔着:“就是那个...”营业员问:“那个什么?”我生气道:“TT啊,你怎么连这暗示都不懂?”营业员连声道歉:“对不起对不起,我没想到你有女朋友。”2、有人问我:“你诚实说,一年你能挣多少钱?”我说:“四五十万吧。”他听后说:“你诚实了吗?”我说:“嗯,我乘1