Code: Alles auswählen
ccRemoteQuery := TccRemoteQuery.Create;
try
ccRemoteQuery.User := 'Test';
ccRemoteQuery.Password := 'secret';
ccRemoteQuery.CreateSession;
try
ccRemoteQuery.Connection := 'EXAMPLE';
ccRemoteQuery.CommandText := 'SELECT * FROM myTable';
ccRemoteQuery.Open;
try
for i:=0 to ccRemoteQuery.RecordCount-1 do
begin
ShowMessage(ccRemoteQuery.GetFieldValueByName('Name',i));
end;
finally
ccRemoteQuery.Close;
end;
finally
ccRemoteQuery.CloseSession;
end;
finally
ccRemoteQuery.Free;
end;