FireDAC.Comp.DataSet.TFDDataSet.FetchBlobs

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure FetchBlobs;

C++

void __fastcall FetchBlobs(void);

Properties

Type Visibility Source Unit Parent
procedure
function
public
FireDAC.Comp.DataSet.pas
FireDAC.Comp.DataSet.hpp
FireDAC.Comp.DataSet TFDDataSet

Description

Retrieves BLOB field values from database for the current record.

Call FetchBlobs to retrieve BLOB field values from a database for the current dataset record, when these values are not provided automatically. BLOB field values are automatically fetched together with other record fields, if fiBlobs is included into FetchOptions.Items, otherwise the automatic fetch operation is not performed.

Example

FDQuery1.FetchOptions.Items := FDQuery1.FetchOptions.Items - [fiBlobs];
FDQuery1.Open;
....
FDQuery1.FetchBlobs;
oStr := FDQuery1.CreateBlobStream(FDQuery1.FieldByName('image'), bmRead);
try
  // process image
finally
  oStr.Free;
end;

See Also