Expert User Tool
The expert user tool shows system information, contains maintenance tools, and offers a direct connection to the database.
System Information
The system information dialog shows how many items are in the database per module, the database name, and the driver that is used to connect to the database.
Maintenance
For now there is only one maintenance tool available, "compact database and
shutdown". This is a direct call to the HSQL database engine.
Information on this tool from the HSQL database website:
"Writes out a new .script file which contains the data for all the tables, including CACHED and TEXT tables. It then deletes the existing text table files and the .data file before rewriting them. After this, it backs up the .data file in the same way as normal SHUTDOWN. This operation shrinks all files to the minimum size".
Performance Tweaking
The inside working of Data Crow can be changed using this panel. Here you can specify the amount of memory to be used by the database and at which interval Data Crow must try to regain memory.
Below you find quotes from the HSQL database website on these settings;
Cache Scale
Indicates the maximum number of rows of cached tables that are held in memory, calculated as 3 *(2**value) (three multiplied by (two to the power value)). The default results in up to 3*16384 rows from all cached tables being held in memory at any time.
Cache Size Scale
Indicates the average size of each row in the memory cache used with cached tables, calculated as 2**value (two to the power value). This result value is multiplied by the maximum number of rows defined by hsqldb.cache_scale to form the maximum number of bytes for all the rows in memory cache. The default results in 1024 bytes per row. This default, combined with the default number of rows, results in approximately 50MB of the .data file to be stored in the memory cache.
SQL Tool
The SQL tool offers a quick and direct way to manipulate data in the database. It overrides all checks on data so it should be handled with care.
If you're not familiar with SQL, you'd be better off not using the SQL Tool
as you might make unwanted changes.
Creating and executing a sql statement
Enter a SQL statement in the "query input" field and press "Run" to execute the statement. Errors will be shown if the query was incorrect (these messages are not generated by Data Crow but by the database engine).
Previously executed statements can be retrieved from the "Prepared SQL statements" list box. You will see that a couple of predefined queries are already in there.
The result of a select query is shown in the "Query result" table.
Note that Data Crow is working on cached representations of the items. When you have executed an update or an insert query you will have to restart the application for the changes to become apparant!