apache derby - explain select

ε祈祈猫儿з 提交于 2019-12-05 20:05:36

问题


I'm programming Java application working with Apache Derby and i'm looking for equivalent for "explain" statement (working for mySQL for example). It's not working in Derby. Is there something similar?


回答1:


There are similar things: Firstly, there is derby.language.logQueryPlan=true, which writes query plan information to the log file: http://db.apache.org/derby/docs/10.8/ref/rrefproper43414.html. Secondly, there is the RUNTIMESTATISTICS feature, which can capture the statistics into your program if you want: http://db.apache.org/derby/docs/10.8/ref/rrefsqlj38831.html. Thirdly, there is XPLAIN style, which captures query plan information into a set of tables inside your database itself: http://db.apache.org/derby/docs/10.8/ref/rref_xplain_tables.html.

You should probably also spend some time reading this: http://db.apache.org/derby/docs/10.8/tuning/ctundepth13055.html



来源:https://stackoverflow.com/questions/5981406/apache-derby-explain-select

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!