Introduction

Mimer SQL is a high performance Relational Database Management System (RDBMS), targeted at mission-critical production environments. This database product offers scaleable performance, including multi-core and multi-threading support, and because it is available on all major Linux, Windows and OpenVMS platforms, it is ideally suited for open environments where interoperability is important.

Mimer SQL’s run-time characteristics, such as high performance, ease-of-use, stability and self-tuning, makes it well suited for software products in a wide span of systems environments. It will fit perfectly in solutions using an embedded DBMS, as well as in enterprise applications where a maximum of database up-time and a minimum of database administration are often required.

Through its 100% conformance to the SQL standards, a native implementation of the ODBC interface and a JDBC driver, a Mimer SQL database can be accessed by a large number of different development tools.

The package

The Mimer SQL distribution for OpenVMS contains the following:

  • Complete documentation.
  • A default license allowing up to ten concurrent users for development and testing.
  • Tools, utilities, libraries, examples, etc.
  • Embedded SQL preprocessor for C, FORTRAN and COBOL.
  • ODBC driver shared library.
  • JDBC 3 compatible driver (requires Java 1.5 or later). The driver is type-4 (100% Java), but it can be configured to load a native library for fast database access (type-2)
  • Client/server support for TCP/IP. The OpenVMS platform can act as both client and server and access Mimer SQL clients or servers on all platforms where Mimer SQL is supported.
  • A performance effective native C API (MimerAPI).

By installing Mimer SQL on a Windows or Linux workstation, the following GUI components can be used to manage objects on Mimer servers running on OpenVMS:

Documentation

Provided with the Mimer SQL distribution package, the Mimer SQL documentation in PDF format can be found. This documentation can be located by following the MIMER$DOC logical name which is defined by the command procedure SYS$MANAGER:MIMER$SETUP_xxxxx, where xxxxx is the version you want to use. The rest of this article assumes you are running 1108A. Read MIMER$DOC:MIMVMS.PDF for further information on product installation on OpenVMS.

Please note that all Mimer SQL documentation can be found on the Mimer SQL Documentation site, including the HTML version of the Mimer SQL OpenVMS Guide.

Unpacking Mimer SQL on OpenVMS

NOTE:

On Itanium, Mimer SQL version 11.0 requires OpenVMS V8.4-2L1 (from VSI) or later. Mimer uses OpenSSL for cryptography and requires SSL1 version 1.0 or later.
On x86_64, Mimer SQL version 11.0 requires OpenVMS V9.2 or later, and SSL 111 V1.1 or later.

The Mimer SQL software is distributed as a self-extracting ZIP file. The file for Itanium has the file name suffix -I64 and the file for x86_64 has the suffix -x86. To unpack the file, simply execute it, and a new directory will be created in your current default directory.

$ SET DEF somedisk:[000000]
$ COPY [somewhere]MIMER1108A-I64.ZIPEXE []
$ RUN MIMER1108A-I64.ZIPEXE

New versions of Mimer SQL for OpenVMS can be fetched from the Mimer SQL Download page.

Installing the Mimer SQL software

Use the command PRODUCT INSTALL to install the Mimer product. Please update the system files mentioned in the installation process.

$ PRODUCT INSTALL MIMER1108A

Define Mimer Commands

Use the command procedure SYS$MANAGER:MIMER$SETUP_1108A to define logical names and Mimer commands for the current process.

$ @SYS$MANAGER:MIMER$SETUP_1108A

Creating a new Mimer SQL database

First create a home directory for your database:

$ CREATE/DIR somedisk:[TESTDB]

Add the database to the SYS$MANAGER:SQLHOSTS.DAT list. Edit the file and add a line under the “LOCAL” section (Add a line like: TESTDB somedisk:[TESTDB]):

$ EDIT SYS$MANAGER:SQLHOSTS.DAT

Create the initial databank files. You may use the default values for all questions except the SYSADM password. Do not forget the password you enter for SYSADM!

$ SDBGEN TESTDB

Start a database server for the database:

$ MIMCONTROL/START TESTDB

Executing SQL statements

We first log in as SYSADM and creates an OS_USER with the same name as the VMS user we are logged in to (PER). This allows us to log in directly into Mimer without providing a user name or password. This only works when the database server is on the same machine as the BSQL session. We also grant the databank privilege to that user to allow him to create a new databank.

$ BSQL
Username: SYSADM
Password: (The one you mustn't forget!)
SQL>CREATE IDENT PER AS OS_USER IDENTIFIED BY 'SECRET';
SQL>GRANT DATABANK TO PER;
SQL>EXIT;

Now we can log in directly without specifying a password. Create a table, fill it with some data and select information.

$ BSQL
Username:
SQL> VALUES(CURRENT_USER);
=================
PER
===

        1 row found
 
SQL>CREATE DATABANK MYDB;
SQL>CREATE TABLE NUMBER(I INTEGER, TXT VARCHAR(32));
SQL>INSERT INTO NUMBER VALUES(1,'ONE');
SQL>INSERT INTO NUMBER VALUES(2,'TWO');
SQL>INSERT INTO NUMBER VALUES(3,'THREE');
SQL>INSERT INTO NUMBER VALUES(4,'FOUR');
SQL>SELECT * FROM NUMBER ORDER BY TXT;

          I TXT
=========== ================================
          4 FOUR
          1 ONE
          3 THREE
          2 TWO
                  4 rows found

Creating the test database

You can use the EXLOAD command to load your database with some more test data. The example database is described in the article called The Example Database.
Three new users are created with known passwords.

$ EXLOAD
Using default database MULTI
SYSADM Password: (enter the secret password)

Example Load parameters:

   SYSADM password:          ******
   Database name:            MULTI
   MIMER_STORE password:     GoodiesRUs
   MIMER_ADM password:       adm
   MIMER_USR password:       usr
   MIMER_WEB password:       web
   MIMER_STORE_DB filename:  mimer_store.dbf
   MIMER_ORDERS_DB filename: mimer_orders.dbf
   MIMER_BLOBS_DB filename:  mimer_blobs.dbf

******  Creating databanks, idents, and tables                    
******  Creating MIMER_STORE schema PSM routines                  
******  Creating the MIMER_STORE_MUSIC schema                     
******  Creating the MIMER_STORE_BOOK schema                      
******  Creating the MIMER_STORE_WEB schema                       
******  Insert data                                               
******  Insert MUSIC details                                      
******  Insert BOOK details                                       
******  Update optimizer statistics after database load           
******  Creating statements                                       
******  Creating synonyms for MIMER_ADM                           
******  Example environment created

Further reading