1. Michał Misijuk
  2. PowerBuilder
  3. Thursday, 8 August 2019 11:18 AM UTC

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. Thursday, 8 August 2019 18:24 PM UTC
  2. PowerBuilder
  3. # Permalink

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

Comment
  1. Michał Misijuk
  2. Monday, 12 August 2019 07:19 AM UTC
Thank You! This sentence explained to me everything.
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Monday, 19 August 2019 16:11 PM UTC
  2. PowerBuilder
  3. # 1

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.
Olan Knight Accepted Answer Pending Moderation
  1. Thursday, 8 August 2019 19:57 PM UTC
  2. PowerBuilder
  3. # 2

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
  1. Olan Knight
  2. Thursday, 8 August 2019 22:37 PM UTC
Chris: Awesome!



Thank You,

Olan
  1. Helpful
  1. Roland Smith
  2. Monday, 12 August 2019 13:05 PM UTC
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. Helpful
  1. Olan Knight
  2. Monday, 19 August 2019 15:47 PM UTC
Yes. TELL ME the bloody row and/or column that is invalid!



Olan
  1. Helpful
There are no comments made yet.
Michael Kramer Accepted Answer Pending Moderation
  1. Thursday, 8 August 2019 12:56 PM UTC
  2. PowerBuilder
  3. # 3

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.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.