I have a Delphi 10.1 Berlin Datasnap Server, that can\'t return Data packets (through a TStream) bigger than around 260.000 bytes.
I have programmed it following the
The problem seems to be neither the TStream class nor the underlying DataSnap communication infrastructure, but that TFDStoredProc component creates a return parameter of type ftBlob. In first place, change the output parameter from ftBlob to ftStream. Then, change GetTables procedure to:
procedure TClientForm.GetTables;
var
LStringStream: TStream;
begin
spStreamGet.ExecProc;
LStringStream := spStreamGet.Params[0].AsStream;
LStringStream.Position := 0;
DataModuleFDClient.FDSchemaAdapter.LoadFromStream(LStringStream,
TFDStorageFormat.sfBinary);
end;