The SqlStatementInfo should include the SQL query. Please add a jira case for this feature.<br><br>Luc<br><br><div class="gmail_quote">On Mon, Mar 11, 2013 at 10:58 AM, Matt Campbell <span dir="ltr">&lt;<a href="mailto:mcampbell@pentaho.com" target="_blank">mcampbell@pentaho.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div link="blue" vlink="purple" lang="EN-US"><div><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d">I believe the statement ID you retrieve from the monitor is the same one that gets logged.  So you should be able to check the ID of any queries still executing and locate them in the logs.  <u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d">E.g. id 202 in this logged entry:<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d">   DEBUG [mdx] <span style="background:yellow">202</span>: select [Gender].[Gender].Members ON COLUMNS<u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d">Alternatively, just look at the logs for queries that have started but not finished.  <u></u><u></u></span></p>

<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1f497d"><u></u> <u></u></span></p>

<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;">From:</span></b><span style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;"> <a href="mailto:mondrian-bounces@pentaho.org" target="_blank">mondrian-bounces@pentaho.org</a> [mailto:<a href="mailto:mondrian-bounces@pentaho.org" target="_blank">mondrian-bounces@pentaho.org</a>] <b>On Behalf Of </b>Domen Pogacnik<br>

<b>Sent:</b> Monday, March 11, 2013 10:10 AM<br><b>To:</b> <a href="mailto:mondrian@pentaho.org" target="_blank">mondrian@pentaho.org</a></span></p><div class="im"><br><b>Subject:</b> Re: [Mondrian] retrieve currently executing sql queries<u></u><u></u></div>

<p></p><div class="im"><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">I know about sql and mdx log, but I would actually like to get the current state of Mondrian i.e. which queries / mdx statements / tasks are currently in execution.</span><u></u><u></u></p>

</div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">To better understand my problem, I often get the following error:</span><u></u><u></u></p>

</div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222;background:white">Mondrian Error:The number of </span><span><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222;background:#ffffcc">concurrent</span></span><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222;background:white"> </span><span><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222;background:#ffffcc">MDX</span></span><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222;background:white"> statements which can be processed simultaneously by this Mondrian server instance has been reached. Set &#39;mondrian.rolap.maxQueryThreads&#39; to change the current limit.</span><u></u><u></u></p>

</div><div><p class="MsoNormal"><u></u> <u></u></p></div><div><p class="MsoNormal"><span style="font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">All the consequential mdx queries after that error fails to execute (even if I wait for 300s). I suspect that there are MDX queries which fail to finish and I would like to see which.</span><u></u><u></u></p>

</div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222"><u></u> <u></u></span></p></div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">Best,<u></u><u></u></span></p>

</div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">Domen<u></u><u></u></span></p></div><div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222"><u></u> <u></u></span></p>

</div><p class="MsoNormal"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">Date: Fri, 8 Mar 2013 13:10:01 -0600<br>From: Matt Campbell &lt;</span><a href="mailto:mcampbell@pentaho.com" target="_blank"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1155cc">mcampbell@pentaho.com</span></a><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">&gt;<br>

Subject: Re: [Mondrian] retrieve currently executing sql queries<br>To: Mondrian developer mailing list &lt;</span><a href="mailto:mondrian@pentaho.org" target="_blank"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1155cc">mondrian@pentaho.org</span></a><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">&gt;<br>

Message-ID:<br>        &lt;</span><a href="mailto:60DAC7BD8D63084E8252254DF3F1102009B4206981@MBX36.exg5.exghost.com" target="_blank"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#1155cc">60DAC7BD8D63084E8252254DF3F1102009B4206981@MBX36.exg5.exghost.com</span></a><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;;color:#222222">&gt;<br>

Content-Type: text/plain; charset=&quot;us-ascii&quot;<br><br>A simple option is to turn on DEBUG logging in your log4j.xml.  Setting both mondrian.sql and mondrian.mdx to DEBUG is often useful.<br><br>   &lt;category name=&quot;mondrian.sql&quot;&gt;<br>

      &lt;priority value=&quot;DEBUG&quot;/&gt;<br>      &lt;appender-ref ref=&quot;SQLLOG&quot;/&gt;<br>   &lt;/category&gt;<br><br>   &lt;category name=&quot;mondrian.mdx&quot;&gt;<br>      &lt;priority value=&quot;DEBUG&quot;/&gt;<br>

      &lt;appender-ref ref=&quot;MDXLOG&quot;/&gt;<br>   &lt;/category&gt;</span> <u></u><u></u></p></div></div></div><br>_______________________________________________<br>
Mondrian mailing list<br>
<a href="mailto:Mondrian@pentaho.org">Mondrian@pentaho.org</a><br>
<a href="http://lists.pentaho.org/mailman/listinfo/mondrian" target="_blank">http://lists.pentaho.org/mailman/listinfo/mondrian</a><br>
<br></blockquote></div><br>