Words:  

Re: Cpu usage of stored procedures

Date: 08-02-10
From: "Alan Chan" <alan_at_belhk.com>

While we never used Store Procedure to do such task, we did these type of
task day in and out in Trigger without problem.

We have table named like Task_trigger that contain Blob field and task ID,
we put arrays in the blob and do whatever we like in the trigger -
updating old data or creates new records on other tables ... etc.

Normally, we split the array into 3,000 at a time to let it update/create
new records in order not to holding down other server operations. Starting
with v11, we split the tasks to a pool of Task_trigger tables.

We have been doing this on 2003 for years without any performance problem.
As we haven't actually deployed v11, we do not know its effect in
production yet.

Alan Chan

4D iNug Technical <4d_tech_at_lists.4D.com> writes:
>The problematic method loops through arrays, creating records in a
>given table, assigning values to fields, then storing the records -
>one at a time ( I know Array to selection would be faster but it still
>doesn't explain the slowdown on the server). It appears that Create
>record and Save record are taking most of the time in the method.
>
>


**********************************************************************
The New 4D Partner Program - All the tools you need to be a successful 4D Developer.
Sign up Now: http://www.4d.com/community/partner/registration.html


4D Internet Users Group (4D iNUG)
FAQ: http://lists.4d.com/faqnug.html
Archive: http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub: mailto:4D_Tech-Unsubscribe_at_lists.4D.com
**********************************************************************