R-tree functionality in HCL Informix

HCL Informix® includes the definition of the R-tree access method and the definition of its default operator class, rtree_ops. However, the support and strategy functions that perform the indexing work are not included; they must be implemented outside the database server, usually as part of a DataBlade® module. The rtree_ops operator class is intended to be used for generic R-tree testing. While you can reuse it, it is recommended that you create a new operator class for each new data type that is to be indexed with an R-tree index.

Newly created Informix databases include only standard data types, such as INTEGER, DATETIME, and VARCHAR. Columns of these data types cannot be indexed with R-tree indexes. Therefore, to create and use an R-tree index, you must add the following objects to your database:
  • One or more user-defined data types that can be indexed with an R-tree index
  • A new operator class for the R-tree access method so that you can create R-tree indexes on the user-defined data type
  • The strategy and support functions required by the operator class

    You must supply the function code in the form of a shared-object library.

To add new data types to the Informix database, you register a DataBlade module that includes the definition of the data types. The DataBlade module might also include a new operator class so you can index the user-defined data type with an R-tree index. For a list of HCL Informix DataBlade modules that include new data types, support and strategy functions, and operator classes, refer to Solutions that use the R-tree access method.

If you are developing a new DataBlade module, read Develop DataBlade modules that use the R-tree secondary access method. It describes in detail how to create the required strategy and support functions in order to create a new operator class. The topic also describes the issues you should be aware of when you design the user-defined data type that will be indexed with the R-tree index.