AdoField:GetChunk()

<< Click to Display Table of Contents >>

Navigation:  Ado Classes > AdoField Class >

AdoField:GetChunk()

Previous pageReturn to chapter overviewNext page

Purpose

Read binary data from a field

 

Prototype

METHOD GetChunk ( lLength AS LONG )  AS USUAL 

 

Argument(s)

lLength        LONG number of bytes to read

 

 

Return

USUAL        String with data, or NIL when field is empty

 

Description

Use the GetChunk method on a Field object to retrieve part or all of its long binary or character data. In situations where system memory is limited, you can use the GetChunk method to manipulate long values in portions, rather than in their entirety.

 

The data that a GetChunk call returns is assigned to variable. If Size is greater than the remaining data, the GetChunk method returns only the remaining data without padding variable with empty spaces. If the field is empty, the GetChunk method returns Null.

 

Each subsequent GetChunk call retrieves data starting from where the previous GetChunk call left off. However, if you are retrieving data from one field and then you set or read the value of another field in the current record, ADO assumes you have finished retrieving data from the first field. If you call the GetChunk method on the first field again, ADO interprets the call as a new GetChunk operation and starts reading from the beginning of the data. Accessing fields in other Recordset objects that are not clones of the first Recordset object will not disrupt GetChunk operations

 

See Also

AdoField, AdoField:AppendChunk()