Accessing BLOB Data

OLE DB Programmer's Reference

BLOBs can be accessed as in-memory data—a sequence of bytes sent or retrieved as a single unit—or as storage objects, through ISequentialStream, IStream, IStorage, or ILockBytes.

The provider can set the DBCOLUMNFLAGS_ISLONG flag to inform the consumer that the provider supports treating BLOBs as storage objects. Although the consumer can still choose to access the BLOB as in-memory data, there might be provider-specific problems in doing so. For example, the BLOB might be truncated due to machine limits on memory. Also, limitations on BLOB columns might apply to binding BLOBs as in-memory data. For example, IRowset::GetData might fail if called more than once for the BLOB. For more information on possible limitations when accessing BLOB columns, see "Limitations of Storage Objects" in this chapter.

If the DBCOLUMNFLAGS_ISLONG flag is not set, the consumer can access the BLOB as in-memory data. It is provider-specific whether the provider supports reading such data through a storage interface. Most consumers allocate sufficient memory to hold such columns in their entirety and treat them as in-memory data.

1998-2001 Microsoft Corporation. All rights reserved.



Microsoft Ole Db 2.0 Programmer's Reference and Data Access SDK
Microsoft OLE DB 2.0 Programmers Reference and Data Access SDK (Microsoft Professional Editions)
ISBN: 0735605904
EAN: 2147483647
Year: 1998
Pages: 1083

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net