Re: Automatic Update of Fields with Oracle 6

From: Michael Porter <mporter_at_earthlink.net>
Date: 1996/04/05
Message-ID: <31661ECC.60C_at_earthlink.net>#1/1


Malachi Wurpts wrote:
>
> We are creating a new database which contains the two following
> fields (among others), these are the desired functions we want from these
> fields.
>
> "update_date" -- everytime the user does a commit the system should
> enter the current date in this field.
>
> "id" -- we want the system to generate this unique id field in
> sequential order (1,2,3....). Each time a new record is created it picks
> the next number in the order.
>
> I'm thinking we can use the Oracle max() function
> and the SysDate function. My question is...
> Is there a way to "attach" these functions to a field
> (using SQL*Plus or something) so that the fields in the
> Database will be automaticaly updated when we do a commit on
> a record? (I was hoping Oracle triggers would do this, but we only
> have Oracle 6).
>
> We're trying to avoid using Oracle forms for this project.
> Can anyone please help?
>
> Please respond to "malachi_at_cs.iastate.edu"
>
> Thank you in advance,
> Malachi Wurpts

Version 6 of Oracle does not provide the mechanisms you seek at the database level. What kind of front end will you be using to perform data manipulation operations on this table?

Unfornately, until you migrate to ORACLE7 (where yes, you do have triggers at the DB level) -- you must perform these "functions" from within the data-entry application, whether it be a PRO*C program, SQL*Forms, Oracle Forms, etc.

Good luck. Received on Fri Apr 05 1996 - 00:00:00 CEST

Original text of this message