title: Can I get the full query that a PreparedStatement is about to execute?
body: <p>I'm working with <code>PreparedStatement</code> with MySQL Server.</p>
  <p>example:</p>
  <pre><code>String myQuery = &quot;select id from user where name = ?&quot;;
  PreparedStatement stmt  = sqlConnection.prepareStatement(myQuery);
  stmt.setString(1, &quot;test&quot;);
  stmt.executeQUery();
  ResultSet rs = stmt.getResultSet();
  </code></pre>
  <p>How can I receive the <strong>full SQL query</strong> that is about to be executed on the <code>MySQL Server</code>?</p>