@Ravaut123, :
, - - , on rowchanges, , .
, disablecontrols, .
...
SQLatable:= 'SELECT SingleField FROM atable ORDER BY indexedfield ASC';
AQuery:= TAdoQuery.Create(Form1);
AQuery.Connection:= ....
AQuery.SQL.Text:= SQLatable;
, , , , . , .
function TForm1.LoadingAllIntoStringList(AQuery: TAdoQuery): TStringList;
var
Field1: TField;
begin
Result:= nil;
try
if not(AQuery.Active) then begin
AQuery.Open;
end else begin
AQuery.First;
end;
AQuery.DisableControls;
AQuery.Filtered:= false;
AQuery.FetchAll;
Result:= TStringlist.Create;
except
{ignore error, will return nil}
end;
try
Result.Sorted:= false;
Result.Capacity:= AQuery.RecordCount;
Field1:= AQuery.FieldByName('SingleField');
while not AQuery.EOF do begin
Result.Add(Field1.AsString);
AQuery.Next;
end; {while}
AQuery.EnableControls;
except
FreeAndNil(Result);
end;
, , SQL. , .
CSV , DB .
MySQL :
SELECT X FROM table1 INTO OUTFILE 'c:/filename_of_csv_file.txt'
CSV.
.