Page 1 of 1

TMSQuery.OpenNext question

Posted: Sat 21 Oct 2006 17:01
by RandySill
Is there any way to determine if a query is a multiresult query? Surely when the command is passed to the server the query component knows if there is another resultset available. When multiresult is executed from SQL Manager, both results are displayed. I would like to be able to emulate this behavior with SDAC.

Randy

Posted: Mon 23 Oct 2006 08:15
by Jackson
You can use construction like following

Code: Select all

  while MSQuery1.OpenNext do begin
    // your code
  end;

Posted: Mon 06 Nov 2006 13:01
by stancosti
if there any other method to know how many resultsets are returned from the server?

using while MSQuery1.OpenNext do... opens all resultsets.

i'm looking for something like ResultCount to iterate.

and also, how may i display two resultsets the same time? calling OpenNext will only display one.

Posted: Tue 07 Nov 2006 10:50
by Jackson
SDAC doesn't support such functionality.
You can not navigate through multiple recordsets in such manner or display several recordsets from one instance of TMSQuery component at the same time using SDAC.