Skip to content

3. Working with Altibase#

This chapter contains the following sections:

  • Supported SQL Statements

  • How to Execute SQL Statements

  • Sample Schema

Supported SQL Statements#

Now that you have created a database and know how to start it up and shut it down, you will of course want to execute some SQL statements, starting with DDL statements for creating database objects such as tables and then DML statements to populate the tables with data and perform similar actions. For a description of the various kind of available database objects, please refer to "Chapter 4: Objects and Privileges".

Altibase Server fully supports the ANSI 92 SQL standard, and additionally provides some extended function. For more detailed description of all SQL statements that are supported by Altibase Server, please refer to the SQL Reference.


How to Execute SQL Statements.#

Statements using the iSQL Utility#

The most straightforward way to execute SQL statements is to use the iSQL utility, which is a command-line interface that ships with Altibase. For more detailed information on how to use the iSQL utility, please refer to the iSQL User's Manual.

Executing SQL Statements using Client Applications Developed by the User#

In addition, SQL statements can also be executed using client applications developed by the user. Please refer to the Chapter: 9 Developing Altibase Application for more detailed information.


Sample Schema#

The Altibase server package contains a script file that has the SQL statements that generate the sample schema. This sample schema includes database tables and other objects. In addition, there are other SQL statements that generate data. Executing $ALTIBASE_HOME/sample/APRE/schema/schema.sql with iSQL as shown below creates the same schemas.

$ isql -s localhost -u sys -p manager -f $ALTIBASE_HOME/sample/APRE/schema/schema.sql

Many of the examples in this manual are based on those sample schemas. If you wish to follow along with the examples, or simply need some sample data on which to execute SQL statements for practice, it is recommended that you execute the above script to create the sample schema.

For more detailed description of all of the objects and data in the sample schema, please refer to the General Reference.