🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #521

Re: Problems with empty recordsets

#521
From: Arnie
Date: Thu, 01 Sep 2005 13:03
33 lines
1912 bytes
George Nakos wrote:
>                      GenQuery->First();
>                      GenQuery->Close();
>
> Here an exception is indeed thrown ("either BOF or EOF is True, 
> or the
> current record has been deleted") and the handler takes care of 
> it,
> as I thought.
>

This probably indicates you need the ADO patch from Borland.  BCB 
5 had two patches, one for the product in general and one for 
ADO.

>
> BTW I'm using BC++5 and MS Access as the database.
>

                     sprintf(send,"SELECT DISTINCT DriverNumber \
 FROM tbl_Drivers Tbl_drivers \
WHERE  DriverNumber = %d",pin);
                     GenQuery->Close();
                     GenQuery->Active=false;        // You don't 
need this.  Close() has already done this
                     GenQuery->SQL->Clear();
                     GenQuery->SQL->Text=send;
                     GenQuery->Open();

                    if ( GenQuery->Eof )
                        // ID doesn't exist

- Arnie
Technical Details
Message-ID: <4316fbe3$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!fr.ip.ndsoftware.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <op.swfb42x5qf2fxd@promitheas.metron.internal>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,a3aa13efef982538
X-Google-Attributes: gid10698b,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Arnie" <none>
Newsgroups: borland.public.cppbuilder.database.ado
References: <op.swfb42x5qf2fxd@promitheas.metron.internal>
Subject: Re: Problems with empty recordsets
Date: Thu, 1 Sep 2005 09:03:44 -0400
Lines: 36
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
NNTP-Posting-Host: 12.29.236.34
Message-ID: <4316fbe3$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1125579747 12.29.236.34 (1 Sep 2005 06:02:27 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!proxad.net!fr.ip.ndsoftware.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail