1. Michał Misijuk
  2. PowerBuilder
  3. Thursday, 08 August 2019

Hi,
I'm having problem with update function.
it gives me result -1 and sqlcode 100, and i can not find out why.

Data window has set update properties (key columns, use update),tab order (not on every column) and everything looks fine, but update still gives me 100.
I learned that 100 says something about retrieve row not found.

is there any way too show actual error message which powerbuilder generate?

Accepted Answer
Roland Smith Accepted Answer Pending Moderation
1
Votes
Undo

One of the rows being updated doesn't exist based on the where clause generated.

Comment
Thank You! This sentence explained to me everything.
  1. Michał Misijuk
  2. Monday, 12 August 2019
There are no comments made yet.
  1. Thursday, 8 August 2019
  2. PowerBuilder
  3. # Permalink
Chris Pollach Accepted Answer Pending Moderation
0
Votes
Undo

Hi Olan;

  I agree ... Not only the row number (which is really the DWO's) but better yet, the primary key value(s) of the failed row.

Regards ... Chris

Comment
There are no comments made yet.
  1. Monday, 19 August 2019
  2. PowerBuilder
  3. # 1
Olan Knight Accepted Answer Pending Moderation
1
Votes
Undo

Michael is most likely correct.


To Armeen and Chris and The Engineers:

   I cannot TELL YOU how much I hate that error message of "Row changed between retrieve and update"! Is there any way to improve the message? Maybe add the row number of the offending row? Maybe include an option to re-retrieve the offending row?

   Something?

   Anything?


Thanks,

Olan

Comment
Chris: Awesome!



Thank You,

Olan
  1. Olan Knight
  2. Thursday, 8 August 2019
The 'Invalid Row/Column' error message is even worse, no easy way to figure it out. Is it the row that was invalid or the column?
  1. Roland Smith
  2. Monday, 12 August 2019
Yes. TELL ME the bloody row and/or column that is invalid!



Olan
  1. Olan Knight
  2. Monday, 19 August 2019
There are no comments made yet.
  1. Thursday, 8 August 2019
  2. PowerBuilder
  3. # 2
Michael Kramer Accepted Answer Pending Moderation
0
Votes
Undo

Hi Michał,

Check DataWindow/DataStore for parameter values in SQLPreview event and DBError event.

My guess is DBError event tells "Row changed between retrieve and update."

HTH /Michael 

Comment
There are no comments made yet.
  1. Thursday, 8 August 2019
  2. PowerBuilder
  3. # 3
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.