Product Documentation

c-treeRTG V2 Update Guide

Previous Topic

Next Topic

SQL Indexes on COBOL Files

c-treeRTG allows you to create a SQL index on your FairCom product tables. You can execute CREATE INDEX on imported tables or you can use the graphical tools, c-treeACE SQL Explorer and c-treeACE Explorer.

Performance of SQL Queries

A practical use of this feature is in handling FairCom product indexes that do not translate well to SQL. In some cases, the index is imported into SQL by sqlize with limited functionality, so it can be used only to perform searches using the "=" and the "<>" (not equal) operators. In a small number of cases, the index cannot be sqlized at all.

These cases may impact the performance of SQL queries on those fields. This issue is now easily addressed: simply create SQL indexes where needed to speed up queries. It is not necessary to replace every FairCom product index, simply replace those that are needed to speed up your SQL queries.

Note: A SQL index cannot be created on FairCom product "bit" data types (Boolean).

Date/time types (date, time, datetime / timestamp) can have additional indexes created if their type definitions are in collation order (YYYYMMDD for dates).

The presence of a SQL index will better optimize some queries. As a side effect, the index returns rows sorted in logical order as opposed to binary order as is the case for FairCom product indexes.

TOCIndex