1. Sripal Bachawat
  2. PowerBuilder
  3. Saturday, 7 July 2018 08:53 AM UTC

In SQL, We have option for On Existing Update or skip where as in Datawindow, we need to first find and take action. If ON EXISTING UPDATE or ON EXISTING SKIP properties, then lot of script writing can be avoided. 

 

 

Roland Smith Accepted Answer Pending Moderation
  1. Sunday, 8 July 2018 20:31 PM UTC
  2. PowerBuilder
  3. # 1

The SQL Anywhere docs say that that feature is not a SQL standard.

Comment
  1. Sripal Bachawat
  2. Saturday, 4 June 2022 10:27 AM UTC
Understood. But any work around ? We have a extensive use case for this in our product. If this feature is there - we can bring almost 50% efficiency in certain commands.
  1. Helpful
  1. Sripal Bachawat
  2. Monday, 27 June 2022 06:03 AM UTC
Anyone can give a workaround ?
  1. Helpful
  1. Roland Smith
  2. Monday, 27 June 2022 13:15 PM UTC
The workaround would be like Mike said, write code that will check for existing and modify the row status prior to calling update so that update generates the correct update/insert SQL statement. You should be able to use the update properties to generically create and run a SQL select to determine if the row exists.
  1. Helpful 1
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Saturday, 4 June 2022 14:43 PM UTC
  2. PowerBuilder
  3. # 2

if you want to actually submit this as an enhancement, you need to enter it as a BUG level P4 and let them know its an enhancement.  

 

fwiw, you can write your own generic code to check for existing during a pre update.  read the update properties to get the primary key and table name to generate the sql to check if a row exists or not.

 

 

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.