Re: pl/sql triggers

From: John <gatess_at_microsoft.com>
Date: Fri, 26 Oct 2001 16:42:41 +0200
Message-ID: <3bd97663$1_at_gaspra.oss.akzonobel.nl>


What I did in this case,
I made a query where records are shown which are not older then a certain date and only those records could be changed. HH

"Frank van Bortel" <fbortel_at_home.nl> wrote in message news:3BC5E2BD.540F9168_at_home.nl...
> riggers wrote:
> >
> > I have a table:
> > create table crime_report (
> > incident_id char (4) not null,
> > crime_locality char (15) not null,
> > crime_date date not null,
> > report_date date not null,
> > cost_of_crime numeric (8,2),
> > officer_id char (4) not null,
> > person_id char (4) not null,
> > crime_id char (4) not null,
> > primary key (incident_id),
> > foreign key (officer_id) references police_office(officer_id),
> > foreign key (person_id) references person(person_id),
> > foreign key (crime_id) references crime(crime_id))
> > cluster csr_report_charge(incident_id);
> >
> > Now I need to create a trigger that checks that crime_reports are not
> > modified if more than a week has passed since the crime was reported.
> >
> > I've been trying for days and just can't work it out (yes a newbie).
> > Any help would be much appreciated.
> >
> > thanks
> > riggers
>
> A trigger is something that needs to be triggered (hence the name...).
> If crime_reports are not modified, nothing happens (or triggers), so no
> trigger
> will ever fire.
> What you need is a procedure that checks periodically.
> Or a smarter reader ;-)
> --
> Gtrz,
>
> Frank van Bortel
Received on Fri Oct 26 2001 - 16:42:41 CEST

Original text of this message