Bulk Update is better in Progress 4GL

Hi Everybody,
I have a quick question;

Query: Performing a Bulk Update is better in Progress 4GL. Please do validate the above statement and If "YES"/"NO", kindly provide your justification on the same...

Let me know if more information is required. Thanks in advance...
 

TomBascom

Curmudgeon
1) What do you mean by "bulk update"? Something like:

Code:
for each customer exclusive-lock:
  discount = discount * 1.1.
end.

2) Better than what?
 
Hi Tom,
Let me put a scenario below that resembles in my Project;

Approach 1:
Consider i have a FOR...EACH loop that scans a table named "xyz" which is a temp-table. I am using this record for validations and finally i do update say 8 tables (not temp-tables). Finally on successful updation i have to update a table named "abc" by finding a record that matches the field in table "xyz".

Approach 2:
In Approach 2 i am adding a new field for xyz which clearly depicts if the validations are successful or not. So after completing the FOR...EACH loop. Now i am doing a join of table "xyz" and "abc" matching the common field and perform a bulk update.

Which one is better???
 

D.Cook

Member
If it's speed you're concerned about, why not test each method with the same data, and see which is quicker?
 
Hi Cook,
I do agree with this approach. But i can't execute and test the performance in PRODUCTION Environment. In DEV Environment we do have very minimal set of data with which i can't come to a decision. :runtear:

Thanks.
 
Top