Article View: borland.public.cppbuilder.database.ado
Article #3255TADODataSet->FieldCount==0
From: Mike Ruskai
Date: Thu, 07 Nov 2002 01:56
Date: Thu, 07 Nov 2002 01:56
31 lines
2303 bytes
2303 bytes
I'm attempting to make result counting optional in my program, so that the initial results of a search are accessible to be examined while the query completes in the background (by ADO, not on a separate thread of my app). The program already lets the user choose a server or client cursor, with a cancel box with the latter so long searches can be aborted (even though ADO will block on the Recordset->Cancel() call if the search involves a sorted result set). After the search, I have a routine which goes through the result set and sets field format information, as well as a few OnGetText handlers to display some fields in human-readable format. With a server cursor, this routine works fine. With a client cursor, it does nothing, because the reported field count is 0, and it has no fields to loop through. I tried putting in a delay loop (with a Sleep() call in the middle) that waited for the field count to not be equal to 0, but it runs forever. With a check of the RecordCount property, however, everything works with a client cursor. So, what can I do to get a field count without checking the record count with a client cursor? -- - Mike Remove 'spambegone.net' and reverse to send e-mail.
Technical Details
Message-ID:
<gunaalqrneguyvaxarg.h56o2w1.pminews@207.105.83.65>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-04!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!proxad.net!proxad.net!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10698b,db15d9f63f3ea0ff,start X-Google-Attributes: gid10698b,public X-Google-ArrivalTime: 2002-11-06 18:12:02 PST Newsgroups: borland.public.cppbuilder.database.ado From: "Mike Ruskai" <spamten.knilhtrae@begonedynnaht.net> Message-ID: <gunaalqrneguyvaxarg.h56o2w1.pminews@207.105.83.65> Date: Wed, 06 Nov 2002 20:56:56 -0500 (EST) Reply-To: "Mike Ruskai" <spamten.knilhtrae@begonedynnaht.net> X-Newsreader: PMINews 2.00.1205 For OS/2 Organization: TLF MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Subject: TADODataSet->FieldCount==0 NNTP-Posting-Host: 65.40.238.148 X-Trace: newsgroups.borland.com 1036634614 65.40.238.148 (6 Nov 2002 18:03:34 -0800) Lines: 33 Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-04!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!proxad.net!proxad.net!fr.clara.net!heighliner.fr.clara.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail