Loading a Dictionary

Use the instructions in this section to load a dictionary for the first time or to upgrade a loaded dictionary to a new version. For more information on upgrading a dictionary, see Upgrading to a New Dictionary Version.

Note:

Oracle is not responsible for the files you upload.

You are solely responsible for obtaining a valid license for any dictionary file(s) you upload. By uploading dictionary files you confirm that you understand all terms that apply to the use of the dictionary.

By uploading a version of WHODrug Enhanced, WHODrug Global, or other Uppsala Monitoring Centre products, you confirm that you hold a valid license granted by the Uppsala Monitoring Centre for the uploaded Uppsala Monitoring Centre product.

This section includes:

Required Setup

Before you load a dictionary, check that you have the necessary setup:

  • Loading data into the temporary tables requires Oracle SQL Loader, which is part of your basic Oracle software package, and is located in the bin directory.

  • Create a new user for loading data into TMS. In the TMS Define Users window, create a superuser and set the Load User? flag to Yes. For more information, see Defining Users.

  • Define the dictionary structure, domains, activation groups, dictionary named relationships and dictionary informative notes attributes (instructions in this chapter and in Defining Other TMS Elements).

  • Download the appropriate sample scripts from My Oracle Support and edit them for your installation. See Downloading Sample Scripts.

About Load Scripts

If you are loading data into TMS, a load script is necessary to move the data from temporary tables to the predict tables (pre-dictionary tables). Your load script must be consistent with your dictionary level and level relation definitions.

Oracle supplies sample load scripts for various dictionaries including MedDRA, MedDRA Primary Path, MedDRA SMQ, WHO-Drug B, B2, and C, and SNOMED on My Oracle Support. The corresponding dictionary structures are described in Sample Dictionary Definitions.

Note:

This documentation is not intended to provide complete and specific instructions for the loading process, which may vary depending on the dictionary and on the individual needs of your location. Rather, these instructions are a guideline by which you can create load scripts that are compatible with your dictionaries. Oracle provides only sample load scripts that are not intended to dictate the usage or maintenance strategy for individual customers. These scripts are supported only to the extent that the API functions are specified.

Load scripts must do the following for each defined element that you are using:

Note:

Using named relations and Informative Notes is optional.

  • Load dictionary terms into tms_predict_contents.
  • Load relations between terms, including named relations, into tms_predict_relations.
  • Load named relation definitions into tms_def_named_rels.
  • Load mappings between named relationships and dictionaries into table tms_def_dict_nrls.
  • Load Informative Notes into tables tms_predict_info_hdrs, tms_predict_info_strs, and tms_predict_info_clobs.
  • Load Informative Note attributes into tms_def_details.
  • Load mappings between Informative Notes and the items they describe or complement—dictionaries, terms, or relations—into table tms_def_dict_info_dets.

For more information, see:

Load Script Requirements

Your load script must:

  • Consist mainly of a series of select statements to transfer data from the temporary tables into the predict tables.

  • Set the DML column value in the predict tables to indicate the transaction to be performed as Insert, Update or Delete for each term and relation.

  • Make use of the constants in the tms_def_dict_cons package to avoid hardcoding constants.

  • Call the necessary packages for all appropriate transactions. The load script for loading a dictionary for the first time only needs to allow for insert transactions, but the load script for updating a dictionary must allow for Insert, Update, and Delete transactions. You can use the same script for loading and updating if it allows for all three transactions. The information on the transaction required for each term and relation is contained in the ASCII files supplied by the vendor.

API Packages

All inserts, updates and deletes must be done using API calls rather than direct DML statements. Some of these packages are explained in The API, and full API descriptions are available in the Oracle Thesaurus Management System Technical Reference Manual, which is available from Oracle Support.

Load Scripts and Activation Groups

The sample load scripts work on one Activation Group at a time, but you can write one that loads more than one Activation Group at a time. By default, when you run the load script, all of the terms in the temporary tables are inserted into the Activation Group you specify. See Creating or Assigning an Activation Group.

Downloading Sample Scripts

Download instructions and sample scripts from My Oracle Support at https://support.oracle.com.

  1. Sign in to My Oracle Support.
  2. Search for Article ID: 258975.1. The article is titled Sample Maintenance Scripts for MedDRA, MedDRA Primary Path, MedDRA SMQ, SNOMED, and WHODrug Formats B2, B3, and C3.
  3. Scroll down to the Attachments section and download the file for the dictionary you want to load.