Skip to content

wangxing-git/mybatis-log-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

74 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mybatis-log-plugin mybatis-log-plugin

MyBatis Log Plugin

Introduction

  • Restore mybatis sql log to original whole sql.
  • It will generate executable sql statements with replace ? to the really param value.
  • Selected the "Filter" button to filter contents that don't wanna display.
  • Selected the "Format Sql" button to format the generate sql statements.
  • Select the console sql log and right-click "Restore Sql" menu to restore sql.

Button Features

  • Sql Text: Restore sql from text
  • Filter: Filter setting
  • Format Sql: Output beautiful formatted sql statements
  • Rerun: Rerun this plugin
  • Stop: Stop filter the sql log

Example

MyBatis Log Test: DEBUG sql1 -  ==>  Preparing: select * from t_table where name = ?
MyBatis Log Test: DEBUG sql1 -  ==> Parameters: hello(String)
MyBatis Log Test: INFO sql2 -  ==>  Preparing: update t_table set name = ? where id = ?
MyBatis Log Test: INFO sql2 -  ==> Parameters: world(String), 123(Integer)
MyBatis Log Test: WARN sql3 -  ==>  Preparing: delete from t_table where id = ?
MyBatis Log Test: WARN sql3 -  ==> Parameters: 123(Integer)
MyBatis Log Test: ERROR sql4 - ==>  Preparing: select * from t_table order by id asc 
MyBatis Log Test: ERROR sql4 - ==>  Parameters: 

MyBatis Log Plugin output executable sql statements:

--  1  MyBatis Log Test: DEBUG sql1 -  ==>
 select *
 FROM t_table
 WHERE name = 'hello';
------------------------------------------------------------
--  2  MyBatis Log Test: INFO sql2 -  ==>
 update t_table set name = 'world'
 WHERE id = 123;
------------------------------------------------------------
--  3  MyBatis Log Test: WARN sql3 -  ==>
 delete
 FROM t_table
 WHERE id = 123;
------------------------------------------------------------
--  4  MyBatis Log Test: ERROR sql4 - ==>
 select *
 FROM t_table order by id asc;

Manual

https://plugins.jetbrains.com/plugin/13905-mybatis-log-plugin/manual

Download

mybatis-log-plugin.jar

Price

Original Price: $?/year
Flash Sale: $1/year

Other Plugin

Smart Jump

About

Restore mybatis sql log to original whole executable sql.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%