Chapter 7: Working with Blob Data

From InterBase
Jump to: navigation, search

This chapter describes InterBase’s dynamically sizable datatype, called a Blob, and describes how to work with it using API functions. Depending on a particular application, you might need to read all or only part of the chapter.

For example, if you plan to request conversion of Blob data from one data type to another, such as from one bit-mapped graphic format to another or from the MIDI sound format to the Wave format, you need to read the entire chapter. To write a conversion routine, called a filter, see Filtering Blob Data. For further information about working with Blob data and filters, see the Embedded SQL Guide.

If you do not need to request conversion of Blob data, then you only need to read the parts of this chapter up to Filtering Blob Data

The following table alphabetically lists the API functions for working with Blob data. The functions will be described and demonstrated in the remainder of this chapter.

Table 7.1 API Blob Functions

Function Purpose
isc_blob_default_desc2() Loads a Blob descriptor with default information about a Blob, including its subtype, character set, and segment size

isc_blob_gen_bpb2() Generates a Blob parameter buffer (BPB) from source and target Blob descriptors to allow dynamic access to Blob subtype and character set information

isc_blob_info() Returns information about an open Blob

isc_blob_lookup_desc2() Determines the subtype, character set, and segment size of a Blob, given a table name and Blob column name

isc_blob_set_desc2() Initializes a Blob descriptor from parameters passed to it

isc_cancel_blob() Discards a Blob

isc_close_blob() Closes an open Blob

isc_create_blob2() Creates and opens a Blob for write access, and optionally specifies a filter to be used to translate the Blob from one subtype to another

isc_get_segment() Retrieves data from a Blob column in a row returned by execution of a SELECT statement

isc_open_blob2() Opens an existing Blob for retrieval, and optionally specifies a filter to be used to translate the Blob from one subtype to another

isc_put_segment() Writes data into a Blob


Topics Covered in this Chapter

Advance to Next Section