提交 f460a407 authored 作者: Thomas Mueller's avatar Thomas Mueller

Documentation.

上级 587c4750
......@@ -468,6 +468,15 @@ To uninstall the service, double click on <code>5_uninstall_service.bat</code>.
If successful, a command prompt window will pop up and disappear immediately. If not, a message will appear.
</p>
<h3>Additional JDBC drivers</h3>
<p>
To use other databases (for example MySQL), the location of the JDBC drivers of those databases need to be
added to the environment variables <code>H2DRIVERS</code> or <code>CLASSPATH</code> before
installing the service. Multiple drivers can be set; each entry needs to be separated with a <code>;</code>
(Windows) or <code>:</code> (other operating systems). Spaces in the path names are supported.
The settings must not be quoted.
</p>
<h2 id="odbc_driver">ODBC Driver</h2>
<p>
This database does not come with its own ODBC driver at this time,
......
......@@ -23,6 +23,7 @@ Change Log
</li><li>Memory mapped file system: improved error messages if there is a problem.
</li><li>The Lucene fulltext search did not work well
when using special file systems such as split or nioMapped.
</li><li>The memory mapped file system (nioMapped: file prefix) couldn't seek past the file length.
</li><li>Some file system operations did not work with stacked file systems
(for example split and nioMapped). This also affected the DeleteDbFiles tool.
</li><li>New experimental query cache.
......
......@@ -354,17 +354,21 @@ if opening the database took more than a few seconds.
<p>
The <code>ConvertTraceFile</code> tool generates SQL statement statistics at the end of the SQL script file.
The format used is similar to the profiling data generated when using <code>java -Xrunhprof</code>.
For this to work, the trace level needs to be 2 or higher (<code>TRACE_LEVEL_FILE=2</code>).
The easiest way to set the trace level is to append the setting to the database URL, for example:
<code>jdbc:h2:~/test;TRACE_LEVEL_FILE=2</code> or <code>jdbc:h2:tcp://localhost/~/test;TRACE_LEVEL_FILE=2</code>.
As an example, execute the the following script using the H2 Console:
</p>
<pre>
SET TRACE_LEVEL_FILE 3;
SET TRACE_LEVEL_FILE 2;
DROP TABLE IF EXISTS TEST;
CREATE TABLE TEST(ID INT PRIMARY KEY, NAME VARCHAR(255));
@LOOP 1000 INSERT INTO TEST VALUES(?, ?);
SET TRACE_LEVEL_FILE 0;
</pre>
<p>
Now convert the <code>.trace.db</code> file using the <code>ConvertTraceFile</code> tool:
After running the test case, convert the <code>.trace.db</code> file using the <code>ConvertTraceFile</code> tool.
The trace file is located in the same directory as the database file.
</p>
<pre>
java -cp h2*.jar org.h2.tools.ConvertTraceFile
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论