Re: Can we have time based triggers in Postgresql??

From: "Jim C(dot) Nasby" <jim(at)nasby(dot)net>
To: Mike Nolan <nolan(at)gw(dot)tssi(dot)com>
Cc: Bob(dot)Henkel(at)hartfordlife(dot)com, Andrew Sullivan <ajs(at)crankycanuck(dot)ca>, pgsql-general(at)postgresql(dot)org, pgsql-general-owner(at)postgresql(dot)org
Subject: Re: Can we have time based triggers in Postgresql??
Date: 2004-04-07 21:54:50
Message-ID: 20040407215450.GM74840@nasby.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Apr 07, 2004 at 08:25:32AM -0500, Mike Nolan wrote:
> > Not that jobs built into the database are of no value, but shell scripts
> > seem to do everything you need and when there are other things to put into
> > posgtresql I wouldn't vote to waste time on jobs.
>
> I wonder if Oracle's time-based jobs feature came to be as a result of some
> other uses for that code, such as snapshots?

I believe there's a lot of other oracle technologies that rely on
dbms_job (oracle jobs). Materialized views and replication are two that
come to mind; there's probably many others.

If you look closely at all the dbms_* procedures oracle has, it's pretty
clear than many of them exist to be of use to higher-level features.
Oracle's mindset seems to be one of doing as much in SQL as is
reasonable, and packaging the building blocks they create for something
like replication as stand-alone utilities so that their customers can
make the same use of them.

> Time-based jobs wouldn't make my top 10 wish list either, though if I had
> them, I'd probably use them.

I tend to agree, but I wish people would stop poo-poo'ing having
something like oracle jobs in pgsql. If you look at how oracle jobs
work, they're not the same as crontab at all. The two reasons you state
are just some of the differences.

> The security aspects of them could be important to some users or
> potential users. Using cron either forces one to have passwords out
> there in plaintext in the .pgpass file or to use a 'trusted' username
> that could also be a major security hole.
>
> Also, a script-based job can be changed or deleted by someone with the
> right file permissions even though they may not have database permissions,
> and vice versa.
> --
> Mike Nolan
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>

--
Jim C. Nasby, Database Consultant jim(at)nasby(dot)net
Member: Triangle Fraternity, Sports Car Club of America
Give your computer some brain candy! www.distributed.net Team #1828

Windows: "Where do you want to go today?"
Linux: "Where do you want to go tomorrow?"
FreeBSD: "Are you guys coming, or what?"

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2004-04-07 22:00:33 Re: How to list domains
Previous Message Josué Maldonado 2004-04-07 21:50:29 Re: Error numbers