Previous Topic: Create an SQL Catalog and Demo DatabaseNext Topic: Configure the TCP/IP Line


Create an SQL Schema to Access Network CA IDMS-Data

To enable SQL access to a network database it is necessary to create an SQL Schema. The SQL Schema is defined in the SQL Catalog and identifies:

No definitions other than the schema are stored in the SQL Catalog.

Note: Even if you do not wish to access your IDMS network data using SQL, we nevertheless recommend that you complete this step, as the example schema you create here is used further on in this scenario when connecting via JDBC or ODBC.

Follow these steps:

  1. Bring up OCF, the CA IDMS online command facility.
  2. Verify that you have the necessary rights to create the SQL Schema:
  3. Type an SQL CREATE SCHEMA statement that identifies the network schema and database instances as follows:
     CREATE SCHEMA schema-name
        FOR NONSQL SCHEMA
        nonsql-schema specification 
        DBNAME nonsql-database-name;
    

    Set the following parameters to appropriate values:

    For example, to create an SQL Schema against the network version of the Employee Demo Database, submit the following statement:

    CREATE SCHEMA EMPSQL
      	  FOR NONSQL SCHEMA
          APPLDICT.EMPSCHM V 100
      	  DBNAME EMPDEMO;
    
  4. Submit the CREATE SCHEMA statement.

    All records in the schema are now automatically accessible as tables, and their elements are visible as columns.

  5. Issue a SELECT statement using the newly created SCHEMA to test that SQL access is functioning correctly. For example, to retrieve all employees using the EMPSQL Schema created above, use the following code:
    SELECT * FROM EMPSQL.EMPLOYEE;
    

Note: For more information about SQL schemas and accessing non-SQL-defined databases, see: