You are here: Symbol Reference > MtxVecDBTools Namespace > Classes > TVecColumn Class > public > TVecColumn.ReadDataset Method
MtxVec VCL
ContentsIndex
PreviousUpNext
TVecColumn.ReadDataset Method

Reads the contents of underlying field and stores it's contents in vector.

Pascal
procedure ReadDataset(ReadAsComplex: boolean = false);

Reads the contents of underlying field and stores it's contents in the Vector vector. Depending on TMtxDataset.ReadWriteMode the following operation is performed: 

 

  • wmRecord => read all Vector properties from current record position. The underlying dataset field must be BLOB field, otherwise an exception is raised.
  • wmColumn => read all values from the underlying field and store them to Vector Values. If the ReadAsComplex parameter is true then two consecutive dataset records are treated as real and imaginary part of complex number. By default, ReadAsComplex is false meaning each record in dataset is treated as one real number. The Vector Length and Complex properties are adjusted automatically.
procedure TForm1.FormCreate(Sender: TObject); begin MtxDataSet.Dataset := Table1; MtxDataSet.VecColumns.Clear; with MtxDataset.VecColumns.Add do begin FieldName := 'TimeAnalysis'; ReadWriteMode := wmRecord; end; with MtxDataset.VecColumns.Add do begin FieldName := 'FFTAnalysis'; ReadWriteMode := wmRecord; end; // read only first field MtxDataset.VecColumns[0].ReadDataset; ViewValues(MtxDataset.VecColumns[0].Vector); end;
void __fastcall TForm1::FormCreate(TObject *Sender) { MtxDataSet->Dataset = Table1; MtxDataSet->VecColumns->Clear(); TVecColumn *col; col = MtxDataSet->VecColumns->Add(); col->FieldName = "TimeAnalysis"; col->ReadWriteMode = wmRecord; col = MtxDataSet->VecColumns->Add(); col->FieldName = "FFTAnalysis"; col->ReadWriteMode = wmRecord; // read only first field MtxDataset->VecColumns->Items[0].ReadDataset(false); ViewValues(MtxDataset->VecColumns-Items[0]->Vector,"",true,false,false); }
Examples on GitHub
Copyright (c) 1999-2025 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!