Thanks Thomas for the response. The query is large. It is 255 lines. We think becuase of the performance of the query, we are seeing lots of BLOCKED H2 threads and application hangs. "H2 TCP Server (tcp://<host:port>) thread" prio=10 tid=0x000000000c1f7000 nid=0x190d waiting for monitor entry [0x00002b0feac15000] java.lang.Thread.State: BLOCKED (on object monitor) at org.h2.engine.Engine.openSession(Engine.java:153) - waiting to lock <0x0000000780da83b8> (a org.h2.engine.Engine) at org.h2.engine.Engine.createSessionAndValidate(Engine.java:138) at org.h2.engine.Engine.createSession(Engine.java:121) at org.h2.server.TcpServerThread.run(TcpServerThread.java:136) at java.lang.Thread.run(Thread.java:701) So we want to check the plan and improve. I have few questions. We have to solve this problem asap, so need help. 1. What other tools we can use on H2 database to get the plan? 2. We have MVCC=true. If one query takes time, is H2 going to block all other threads? I read from other post that H2 by default execute one thread at a time. To prevent other threads from getting blocked, we have to use MULTI_THREADED=1 and remove MVCC. Is there any limit on number of threads if multi_threaded is used?
On Tuesday, October 14, 2014 1:50:46 AM UTC-4, Thomas Mueller wrote: > Hi, > > Well, that means the query plan is huge. How large is the query? I'm > afraid you need to either use a different tool to display the plan, or you > need to make the query shorter. > > Regards, > Thomas > > > On Monday, October 13, 2014, Sarmistha Samantaray <[email protected] > <javascript:>> wrote: > >> I have a bug query and want to check the explain plan. The result window >> doesn't show full result. It has only few lines of query and ellipsis. How >> can I see full explain plan? >> >> SELECT >> T1.NAME AS INSTALLATION, >> T1.TIME_RANGE, >> IFNULL(NUM_PATIENTS_ENTERED_WR, 0) AS NUM... (165545 characters) >> >> -- >> You received this message because you are subscribed to the Google Groups >> "H2 Database" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To post to this group, send email to [email protected]. >> Visit this group at http://groups.google.com/group/h2-database. >> For more options, visit https://groups.google.com/d/optout. >> > -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/h2-database. For more options, visit https://groups.google.com/d/optout.
