× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Booth,

Why don't you test it?

- Build a trigger; clear the file, add 20000 records and measure the time
- Create a program that processes 20000 records (and does the same things
the trigger does, of course) and measure the time

I don't think 'pulling the trigger' is a heavy operation, once the trigger
is activated (assuming you don't do anything silly like using CL, OPM or
activation group *NEW).

IOW: I expect that the lion's share of the time used will be in processing
the record; that will have to be done 20000 times either way. I don't
expect that calling the trigger 20000 times will add significant time.

And another thing: when 20000 records are inserted, how are you going to
make sure nothing happens to the file while you are processing those
records? Allocate it? There will be some additional housekeeping in that.
With a trigger you don't have to worry about that aspect.

Joep Beckeringh
Software architect
Pantheon Automatisering B.V.
Heerenveen


Booth Martin <booth@xxxxxxxxxxxx>

12-09-2018 08:34

Re: run a program when a file changes

The entire file is cleared and new records inserted several times a
day. If I attach an on-insert trigger and 20,000 records are inserted,
that means the trigger is pulled 20,000 times?

That sounds harsh to me? So it seems prudent to ask.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.