home *** CD-ROM | disk | FTP | other *** search
/ Complete Linux / Complete Linux.iso / docs / apps / database / postgres / postgre1.z / postgre1 / video / script-17 < prev    next >
Encoding:
Text File  |  1992-08-27  |  304 b   |  10 lines

  1. /* 
  2.  * we can also use rule to handle view updates.
  3.  * For example, to handle insertion to toyemp we can define the rule:
  4.  */
  5. define rewrite rule toyemp_app is
  6. on append to toyemp do instead
  7. append emp(name = new.name, age = new.age, location = new.location,
  8.     dept = "toy", salary = new.annualsal/12)
  9. \p
  10.