The IfxMRData data type

The IfxMRData data type is a multirepresentational opaque type, defined in the HCL OneDB™ Text Descriptor DataBlade® Module for use with the . It provides for fast and efficient storage of ASCII text data.

The main advantage of using the multirepresentational IfxMRData data type is that it dynamically determines whether to store your documents as LVARCHAR or CLOB data structures, depending on the size of the documents. Documents smaller than 2 KB are stored as LVARCHAR objects, and documents greater than 2 KB are stored as CLOB objects.
Important: The precise cutoff point between storing documents as either LVARCHAR or CLOB data structures is 2040 bytes, and not 2048 bytes. This difference is due to the 8 bytes used to store the data structure itself.

Inserting data into an LVARCHAR column is faster than inserting data into a CLOB column, so to speed up performance it is preferable to use LVARCHAR whenever possible. LVARCHAR columns, however, have a size limitation of 2 KB. Since it is often difficult to know ahead of time what the maximum size of a document is, it is risky to use a column type of LVARCHAR. Specifying a column type of IfxMRData solves this problem because the data type itself determines whether your document is be stored as an LVARCHAR or a CLOB data structure.

You can use the IfxMRData data type with ASCII text data only, because it uses CLOB, and not BLOB, as a possible storage type. If your documents contain binary data, do not store them in columns of type IfxMRData, but in columns of type BLOB instead.

Updating a column can change where the data is stored. For example, suppose a document is initially stored as a CLOB type because its size is over 2 KB. CLOB data is stored in an sbspace. If you update the value so that the size of the document is smaller than 2 KB, the DataBlade module changes its storage to LVARCHAR, which is contained within the database. This change is transparent to users.