简体   繁体   中英

Can I inspect the database in the current transaction when debugging?

I have a Java web app (Jetty over MySQL). I'm trying to find a bug in a big chunk of code, all under one transaction. It would be useful to be able to inspect the database at certain points in the code - is there a nice way to do it (some tool or Eclipse plugin)?

I'm looking for something like the inspector available for HSQLDB. I could probably get hold of the current session and run arbitrary XML on it via 'Expressions' view in Eclipse debug mode, but that won't be pretty, I'm sure.

EDIT: scratch that, I only now noticed that what I thought was some special tool that comes with HSQLDB is merely an internal wrapper for DatabaseManagerSwing. I'll try to bend it to my will.

如果使用的是原始JDBC,则可能会看到MySQL驱动程序属性 ,尤其是“调试/概要分析”部分。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM