The demo data for the SQL Tutorial represents an extremely basic hotel administration system with information on the hotel’s visitors, location, vacancies, room prices, and so on.
This simple demo data is sufficient for you to work with all examples in this SQL tutorial.
You can change the demo data to suit your needs. However, your results may then deviate from the example results given in this tutorial.
1. Install the database software and tools.
To do so, proceed as described in Installation Manual.
2. Create the database instance DEMODB. You can use the Installation Manager or the Database Manager to do so.
Do NOT load the demo data.
Installation Manual, Creating the Demo Database Instance DEMODB
Database Manager GUI, Creating a Database Instance: Desktop PC/Laptop
Database Administration Tutorial, Creating and Configuring a Database Instance
You can use different tools to create database users (Loader, Database Manager, for example, Database Manager GUI or CLI, query tools, such as SQL Studio, SQLCLI). The following sections describe how to enter the SQL statements for creating the database user MONA with the SQL Studio.
1. Log on to the demo database instance DEMODB as a database system administrator using the SQL Studio.
If you copied the default values when you created the demo database instance DEMODB, the database system administrator has the following user data:
user name: DBADMIN, password: SECRET
2. Create the database user MONA with the following SQL statement:
CREATE USER mona PASSWORD red DBA NOT EXCLUSIVE
3. Log off from the SQL Studio.
You can use various tools to create objects in the DEMODB demo database instance and populate them with demo data (Loader, Database Manager CLI and query tools such as SQL Studio, SQLCLI).
The following sections explain how to execute the SQL statements specified for the HOTEL schema for creating the database objects and their contents with the SQL Studio.
4. Using the SQL Studio, log on to the demo database instance DEMODB as user MONA with the password RED.
5. Create the HOTEL schema and the required tables and fill these with values.
Use the SQL statements as specified in SQL Statements for the HOTEL Demo Schema.
Database user MONA has been created in the DEMODB demo database instance as a database administrator (DBA) with the password RED. The database administrator MONA can open several database sessions at once (NOT EXCLUSIVE).
The HOTEL demo schema has been created. A series of simply-structured tables have been assigned to the HOTEL schema. The tables are filled with demo data.
If you want to learn to administer database instances using the DEMODB or test SQL statements or Loader commands using existing data, you can load a more extensive set of demo data into the database instance DEMODB by executing specified scripts.
To load the complete demo data in this case, select the corresponding Load Tutorial option when creating a database instance in the Installation Manager and the Database Manager GUI.