Advertisement
joshuaboshi

Untitled

Jul 26th, 2011
188
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. CREATE TYPE base.base AS
  2.    (xx timestamp without time zone,
  3.     yy timestamp without time zone,
  4.     zz timestamp without time zone);
  5.  
  6.  
  7. CREATE OR REPLACE FUNCTION sch."updateTimestamp"()
  8.   RETURNS trigger AS
  9. $BODY$
  10. BEGIN
  11.     (NEW.base).xx = now();
  12.     RETURN NEW;
  13. END;
  14. $BODY$
  15.   LANGUAGE plpgsql VOLATILE;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement