Article View: borland.public.cppbuilder.database.multi-tier
Article #1487Re: BDE Error (probably a bug in something)
From: Jerry Bloomfield (TeamB)
Date: Thu, 07 Oct 1999 00:00
Date: Thu, 07 Oct 1999 00:00
40 lines
2590 bytes
2590 bytes
On Wed, 06 Oct 1999 20:01:08 +1000, Michael Farr <farrm@lion.cs.latrobe.edu.au> wrote: >One of the Fields returned by the TQuery is a double > >I can edit this Column in the Grid as much as I like ... until I make it >negative. As soon as it goes negative I cant edit it again ... it gives >me the: "Another user changed the record" line ... most upsetting. I >can edit all the other records fine, just not the negative ones. I went >to the trouble of making a blank form with these components, just to >make sure it wasnt any of my other code doing this. Restarting the >server, my workstation and running around in circles does not fix this >problem. > >(Hope its not really a bug) Regretfully, this is worse than a bug. It is a design flaw... What appears to be happening to you is that the interface to your database and the database itself are not handling the floating point "rounding" in the same manner. In the end it causes the BDE to not be able to locate the exact record it is looking for (due to the floating point issues) and it can only assume that since you read the record and it is no longer there, that someone else has changed it. In fact, the record is still there, it is just that the floating point comparisons do not match-up exactly, and therefore it doesn't look like it is still there... Some possible work-arounds would be to not use any floating point fields in any of your records. Since you probably can't go this drastic, you could go to not using them in your record key fields, then performing your edits based on the key fields only (by setting the UpdateMode property). Other than those options, you don't have much hope, unless you can get an updated driver which handles the floating point "rounding" issues a bit better... Jerry Bloomfield (TeamB) -- Jerry Bloomfield JersWork@wwa.com Proud Member of Borland's TeamB "We'll do anything if you don't pay us."
Technical Details
Message-ID:
<T2v9N3OksCvlVLHYC4DIq6p4W8nl@4ax.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<37FB1DE4.22BCD7F@lion.cs.latrobe.edu.au>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fcd2b,b20b4271659480f8 X-Google-Attributes: gidfcd2b,public From: "Jerry Bloomfield (TeamB)" <JersWork@wwa.com> Subject: Re: BDE Error (probably a bug in something) Date: 1999/10/07 Message-ID: <T2v9N3OksCvlVLHYC4DIq6p4W8nl@4ax.com> X-Deja-AN: 534183854 Content-Transfer-Encoding: 7bit References: <37FB1DE4.22BCD7F@lion.cs.latrobe.edu.au> Organization: LSVFA - Latest Software Version Freaks Anonomous Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 Newsgroups: borland.public.cppbuilder.database.multi-tier