Hopefully this is just another newbie question and I'm missing the
obvious...
In Delphi 3, is there a way to execute a query that returns multiple results
sets and actually do something with them, or alternatively, is there a way
to execute a query and perform some action as each row is fetched (not
after)?
My problem is I'd like to let a user execute a query that they specify and
return the results. The query may have 0, 1 or more result sets. I'm
looking to simply format the results as text; nothing fancy, no grids or
tables. My problem is that all the TDataSet objects assume one result set,
and there doesn't appear to be (or I can't find it) a way to get into the
actual retrieval of data; no way to hook the row fetching process.
I know how to do this if I was righting in C (w/o the BDE), or PowerBuilder
of that matter. In both I could start fetching results, when one result set
finished, continue fetching until I exhausted all result sets. As each row
was fetched I could do whatever I wanted with the results, perhaps storing
in multiple arrays, converting them to text and appending to a string, or
simple processing and then discarding. But the BDE doesn't seem to give the
programmer a way to process a row at a time.
Am I missing something? Is there anyway to do this?
TIA,
Tim Green