Home | Previous Page | Next Page   Managing Databases That Use the R-Tree Secondary Access Method > System Catalogs >

sysopclasses

The sysopclasses system catalog stores information about operator classes. Each time a new operator class is created with the CREATE OPCLASS statement, a row is added to this table.

Some of the columns of the sysopclasses table include:

The following query returns all columns of the sysopclasses system catalog for the MyShape_ops operator class:

SELECT * 
FROM sysopclasses
WHERE opclassname = 'myshape_ops';

opclassname  myshape_ops 
owner        informix 
amid         2 
opclassid    100 
ops          overlap;equal;contains;within;  
support      union;size;inter;sfcbits;objectlength;sfcvalue;setunion;  

Tip:
Because Informix always converts object names to lowercase when updating system catalogs, the preceding query searches for the myshape_ops operator class instead of the MyShape_ops operator class.

The query shows that the strategy functions for the MyShape_ops operator class are Overlap, Equal, Contains, and Within. The support functions are Union, Size, and Inter, as required. The MyShape_ops operator class also defines the bottom-up building support functions SFCbits, ObjectLength, SFCvalue, and SetUnion.

The following query of the sysprocedures table returns information about the available Within strategy functions, such as their signatures and connections to the shared library:

SELECT paramtypes, externalname
FROM sysprocedures
WHERE procname = 'within';

paramtypes    myshape,myshape  
externalname  
$INFORMIXDIR/extend/shapes.3.0/shapes.bld(MyShapeWithin) 

The result shows that a Within function exists in the database for the MyShape data type.

To determine the operator classes that are already available in your database for the R-tree access method, execute the following query:

SELECT opclassname, opclassid
FROM sysopclasses, sysams
WHERE sysopclasses.amid = sysams.am_id AND
      sysams.am_name = 'rtree';

opclassname  rtree_ops 
opclassid    2  

opclassname  myshape_ops 
opclassid    100 

The result shows that the database contains two operator classes that can be used with the R-tree access method: rtree_ops and myshape_ops.

Important:
If you have registered a DataBlade module that supplies its own operator class, you must specify it when you create an R-tree index. Do not specify the default rtree_ops operator class.

For a complete description of the columns of the sysopclasses system table, refer to the IBM Informix: Guide to SQL Reference.

Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]