#
Create a H2 Database Schema
This tutorial explains to you how you can create a H2 database schema.
H2 is an open source database written in Java. H2 database can be embedded in Java applications or run in the client-server mode.
H2 database can be configured to run as in-memory database, which means that data will not persist on the disk, but the access is very fast.
H2 provides transaction support (read committed), 2-phase-commit and table level locking.
H2 supports encrypted database (AES), SHA-256 password encryption, encryption functions and SSL.
If you want to create a H2 database schema, it is a simple task. You can use the H2 database Console, but you have to type and run the command in order to create a schema:
Info
If no owner is specified, the current user is used. The user that executes the command must have admin rights, as well as the owner. Specifying the owner currently has no effect. Optional table engine parameters are used when CREATE TABLE command is run on this schema without having its engine params set. This command commits an open transaction in this connection.
When you run the command into the H2 database Console you see if the command run or not. If the command run without errors, you see also the execution time:
Now you can verify if the new H2 database schema is added in the list: