Database query
This feature helps administrators access database data easily and quickly without third-party database client software.
The results of the queries can be exported to SQL or CSV file formats.
Allowed types:
Type | Description | List | Export |
---|---|---|---|
JDBC |
SQL queries supported by the configured database. |
When chosen, a list of available tables is shown. |
Yes. |
Hibernate |
Neutral database queries based on the Hibernate query format. |
No. | |
|
Execute JDBC query
- On the bottom right choose the JDBC type.
- Write some valid SQL.
- Click on the Execute button.
- Optionally, the results can be exported to SQL or CSV
- Click on
Export to SQL icon.
- Click on
Export to CSV icon.
- Click on
Example:
// nodeBase = documents + folders + mails + records
SELECT count(*) from OKM_NODE_BASE;
SELECT count(*) from OKM_NODE_DOCUMENT;
SELECT count(*) from OKM_NODE_FOLDER;
SELECT count(*) from OKM_NODE_MAIL;
SELECT count(*) from OKM_NODE_RECORD;
// select first 10 records
SELECT * from OKM_NODE_BASE LIMIT 10;
SELECT * from OKM_NODE_DOCUMENT LIMIT 10;
SELECT * from OKM_NODE_DOCUMENT_VERSION LIMIT 10;
SELECT * from OKM_NODE_FOLDER LIMIT 10;
SELECT * from OKM_NODE_MAIL LIMIT 10;
SELECT * from OKM_NODE_RECORD LIMIT 10;
Execute Hibernate query
- On the bottom right choose the Hibernate type.
- Write some valid HQL.
- Optionally, you can check the "Show SQL" option.
- Click on the Execute button.
When the "Show SQL" option is checked, the results show the real SQL executed.
Example:
select count(*) from NodeBase;
select count(*) from NodeFolder;
Allowed sentences
- On the bottom right choose a valid SQL file.
- Click on the Import SQL Script button.