I’m investigating why 2nd and subsequent opening of large queries is taking way longer than the 1st opening (E.g 1st opening = 7s, 2nd = 25s) and I’m wondering if it’s trying to load the schema (which is always been really slow).
I am building the fields programmatically before calling open and I have the RemoteDataAdapter.CacheSchema = True. I wouldn’t expect the schema to be re-loaded, but I’d like to be sure, so…
…what triggers a TDAMemDataTable to Load a Schema during an open call ?
can you create a simple testcase that reproduces this behavior, pls?
Schema is loaded when table.Fields.Count = 0.
you can uncomment {.$DEFINE BIN2DEBUG_time} definition in uDABin2DataStreamer.pas
it will generate some debug information via OutputDebugString so you can see what is wrong.
I would appear that the problem was with the UI in the form - I wasn’t properly disconnecting the Grid from the TDAMemDataTable before clearing the grid columns.