#1 2020-04-07 17:19:30

mrauter
Member
Registered: 2016-11-18
Posts: 2

Converting ISQLDBRows to TDocVariantData

Hello,

I want to fetch all the results from the database to a TDocVariantData, right now I am using the following code:

procedure Test;
var
  FRows: Variant;
begin
    Props:= TOleDBMSSQL2012ConnectionProperties.Create(Server, DBName, user, pass);
    FRows:= _Json(Props.Execute('select * from MFOR', []).FetchAllAsJSON(true)); 
    [Code...]
end;

Is there a way to directly fetch the results to an TDocVariantData? Like "Props.Execute('select * from MFOR', []).FetchAllAsDocVariant";

And I wanted to thank you for your amazing work with mORMot, it's setting a higher standard for Delphi programming.

Offline

Board footer

Powered by FluxBB