× 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.



I agree with Joel. .

What Joel is talking about is what is called a Temporal database (Based on
time). Everything is time stamped and you can always see what the database
looked like at any given time. In this case, you are taking one file.

To make it work you are going to need two time stamp fields, not date
fields, one for start and one for end. The first record written for a given
key always gets the current time stamp and the ending gets a null or
0001-01-01-00:00:00:00000 value.

When the record is updated the end value is set to current time stamp and a
new record created with current time stamp for start and null for end.

This sort of thing work best with a primary key being an identity key so
that is record has a unique id.

If you can't do that journal make sense to me.You can also do journaling in
almost real time. Use RCVJRNE and write to your log file.

If you think you must use triggers look at my Trigger Mediator at
www.think400.dk/downloads.htm. Gives you the ability to manage triggers.

Anyway, my two cents.. .


On Wed, Oct 30, 2013 at 3:50 PM, Raul A. Jager W. <raul@xxxxxxxxxx> wrote:

The trigger writes a easily readable file, the jounal is more for
auditing by skilled users.

Monnier, Gary wrote:

Why use a trigger when you can journal the table? The journal has job
info, creation date, job identifier, program making the change and even
remote IP address in addition to having the entire row's contents.

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:
midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Jeff Crosby
Sent: Wednesday, October 30, 2013 12:44 PM
To: Midrange Systems Technical Discussion
Subject: Log file of file changes

All,

We had an issue recently about how a couple of prices got changed. The
salesrep (who has _some_ control over pricing) says he didn't do it, and no
one in the office remembers doing it. In fact, it was the sales rep who
brought it up wanting to know what the %#@* is going on? :) By looking at
month end backups, I know it happened sometime in August. Nothing like
bringing it to our attention on a timely basis, right?

Anyway, in discussing it, the buying VP suggested a log file of changes.
I think it's a great idea and it seems to me to be an ideal use for a
trigger. Whenever a record is added/updated/deleted, just have the trigger
write the record to this log file. It can have the same record layout as
the file in question, plus add a few fields such as user and timestamp.
Seem reasonable? I've never written a trigger before but I can figure
it out.

The file is currently journaled, but that's not really what journaling is
for, IMO.

Thanks for any ideas.

--
Jeff Crosby
VP Information Systems
UniPro FoodService/Dilgard
P.O. Box 13369
Ft. Wayne, IN 46868-3369
260-422-7531
www.dilgardfoods.com

The opinions expressed are my own and not necessarily the opinion of my
company. Unless I say so.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.




--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.