pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter_e@gmx.net>
To: Wolfgang Fürtbauer <w.fuertbauer@eunet.at>
To: pgsql-odbc@postgresql.org
Subject: Re: Problem with VB6, DAO, Data Control: Update does not work
Date: Fri, 13 Aug 2004 23:53:44 +0200
Message-ID: <200408132353.44050.peter_e@gmx.net> (raw)
In-Reply-To: <6.0.3.0.2.20040813204437.026d24e0@mbox.tiscali-business.at>
References: <6.0.3.0.2.20040813204437.026d24e0@mbox.tiscali-business.at>

Wolfgang Fürtbauer wrote:
> I found out, after removing the "rabwert" = '5.225'::float4 from the
> where-clause,
> the update worked; so I had a look with the VB-Debugger at the value
> of data1.recordset!rabwert
> just before update and: the value was 5.225
>
> Why does the update not work ?

You can't reasonably compare floating point values for equality, because 
they only store approximations of what you see.  And you certainly 
shouldn't store monetary values in floating point columns, because you 
are asking for rounding problems.  Always use numeric.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/




view thread (5+ messages)  latest in thread

Message-ID: <200408132353.44050.peter_e@gmx.net>
Permalink:  ../200408132353.44050.peter_e@gmx.net/
Also on:    postgresql.org/message-id/200408132353.44050.peter_e@gmx.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-odbc@postgresql.org
  Cc: peter_e@gmx.net, w.fuertbauer@eunet.at
  Subject: Re: Problem with VB6, DAO, Data Control: Update does not work
  In-Reply-To: <200408132353.44050.peter_e@gmx.net>
  References: <6.0.3.0.2.20040813204437.026d24e0@mbox.tiscali-business.at> <200408132353.44050.peter_e@gmx.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox