At 10:15 AM 10/09/2011, Aage Johansen wrote:
>This problem hasn't received any comments, and - as I am rather 
>interested in an explanation - I will try to revive the thread.
>
>A couple of days ago SET wrote:
><<
>This morning I got very surprised. I ran (something similar to)
>
>UPDATE MyTable M
>SET M.MyField = 'Y'
>WHERE M.MyPK = :MyPK
>
>repeatedly in Database Workbench (4.1.2.0) because a program I have 
>gave me a strange message.
>
>Sometimes this updates one row in the table, sometimes not. Running
>
>SELECT * FROM MyTable M
>WHERE M.MyPK = :MyPK
>
>always returns a row, though the values varies depending on whether 
>the above update altered the row or not.

I don't get what you mean by this.  You might get "inconsistent" output if the 
update transaction and the select were in different transactions, regardless of 
whether the update actually changed anything.


>I've tried recreating the PK and various other stuff, the only thing 
>that seems to help is to use a constant rather than a parameter (not 
>a good solution as this is done iteratively in my program). MyPK is 
>an integer, so it should not be related to floating point values. The 
>server should be Firebird 2.1.3 SS, I think the database was restored 
>from a backup when it was moved from Fb 1.5.

It should be worth checking the ODS of the database, rather than guessing that 
it's probably 11.1.


>Has anyone encountered anything similar 

Myself not, but...

>or has a clue as to what this may be?

It does sound similar to what was happening back in the 2.0 era when people 
were using old IBO components with ODS 11 databases.  I think it would be good 
to have all these versions of things clear.  IBO 4.7 and below did not play 
well with ODS 11.anything databases.  I'm not saying that the answer is jumping 
out at us but it would make sense to know exactly what you're working with.

>One more observation:
>It also fails with Firebird 2.5.0 (backup made with Fb/2.1, restored with 2.5)
>Also, DBW is using IBO components (not the latest ones).  I belive 
>SET also tested with a Delphi program, in which case IBO components 
>were used as well.

1. Has anyone actually looked at the SQL monitor to see what values are being 
passed in the params?
2.  Does the (now unsupported) OldParameterOrdering parameter ring a bell with 
you at all?  The IBO version would be pretty crucial if it was an issue you 
addressed for ODS 10.x databases and subsequently forgot about.

./heLen

Reply via email to