Hi! I'm using MSSQServer+Zeos+TDataSetProvider+TClientDataSet to obtain data in Master-Detail mode.
All works fine but I would like load all related rows except blobs fields and use any function for retrieve it in ClientDataSet opened.
When I set poFetchBlobsOnDemand = true the effect is the same. I think that ClientDataSet is retrieving all blobs files because the SQL execute is slow too. If I run a trace on the server, I see that blob fields are included in "Select".
How could I do it? Is the combination Zeos/MSSQServer does not work?
What i'm doing wrong? Maybe I just is missing some detail. I would greatly appreciate to give me a clue
regards
Tavo
TDataSetProvider.Options := [poFetchBlobsOnDemand]
Moderators: gto, EgonHugeist
- mdaems
- Zeos Project Manager
- Posts: 2766
- Joined: 20.09.2005, 15:28
- Location: Brussels, Belgium
- Contact:
Hi,
I'm not sure if poFetchBlobsOnDemand should prevent the dataset to fecth the BLOBs or if it only influences the way BLOB's are exchanged between Tprovider and TClientDataset
From the documentation in Delphi on poFetchBlobsOnDemand I read:
Pushing this to the level of database communication in a db protocol agnostic way would be a hell of a job, as not every database API allows for fetching BLOBs just using a pointer at the moment you need them.
To solve your problem I think you you should think about using a separate dataset to fetch the blobs you need on demand. This will cause more connections between your database and you appserver, but only retrieves the data you want to send to the server. With BLOBs this might make a terrible difference.
Mark
I'm not sure if poFetchBlobsOnDemand should prevent the dataset to fecth the BLOBs or if it only influences the way BLOB's are exchanged between Tprovider and TClientDataset
From the documentation in Delphi on poFetchBlobsOnDemand I read:
This seems to refer only to network communication between the client application and the application server. Not to the dataset workings inside the application server.BLOB fields are not included in data packets. Instead, client applications must request these values on an as-needed basis. If the client dataset's FetchOnDemand property is true, the client requests these values automatically. Otherwise, the client application uses the FetchBlobs method to retrieve BLOB data.
Pushing this to the level of database communication in a db protocol agnostic way would be a hell of a job, as not every database API allows for fetching BLOBs just using a pointer at the moment you need them.
To solve your problem I think you you should think about using a separate dataset to fetch the blobs you need on demand. This will cause more connections between your database and you appserver, but only retrieves the data you want to send to the server. With BLOBs this might make a terrible difference.
Mark