MDAC 2.5 SDK - OLE DB Programmer's Reference
Chapter 6: Getting and Setting Data


 

Length

The length of a data value is its size in bytes as it is stored in the consumer's data buffer. When the consumer gets data, length is the size of the data after it is converted from the provider type to the consumer type. When the consumer sets data, length is the size of the data before it is converted from the consumer type to the provider type.

The consumer specifies the buffer length with the cbMaxLen element of the DBBINDING structure. For information about how the provider uses the buffer length in conjunction with the data length, see cbMaxLen in "DBBINDING Structures," later in this chapter.

Length Values

The length value itself is a ULONG. The value stored in this ULONG depends on the data type as follows: