[SQL] rules on select - different output

2000-12-03 Thread Marcin Mazurek
Hi, I'd like my rule to change the row which is resulting form select. I'd like to get a row conforming to t1 from t2. CREATE TABLE t1 (id int, f1 int, f2 int, f3 text, f4 text); CREATE TABLE t2 (id int, p1 int, p2 text); CREATE RULE r1 AS ON SELECT TO t2 DO INSTEAD SELECT id, p1 AS f1, NULL::

Re: [PHP-DB] Re: [SQL] a script that queries database periodically

2000-12-03 Thread Jason
On Mon, Nov 27, 2000 at 02:56:59PM -0700, Roberto Mello wrote: > > PHP does not have a scheduling facility? AOLserver (the web/application > server that powers AOL) has had such facility (and many many others for > db-backed websites) since 1995. ns_schedule_proc. > http://www.aolserv

Re: [PHP-DB] Re: [SQL] a script that queries database periodically

2000-12-03 Thread clayton cottingham
Roberto Mello wrote: > > Jason wrote: > > > > aolserver is a web/application server. PHP is a server-side scripting > > language. Why exactly *should* it have a job scheduler? > > > > Some (such as myself) might also ask why should a web server have a job > > scheduler, but that's a thread for

[SQL] FW: Sharing Databases

2000-12-03 Thread Yoghini Thevarajah
-Original Message- From: Yoghini Thevarajah [mailto:[EMAIL PROTECTED]] Sent: Monday, November 27, 2000 1:06 PM To: [EMAIL PROTECTED] Subject: FW: Sharing Databases Need help desperately. Is is possible at all to share tables between different databases. In SELECT query need to make

[SQL] Access Permissions/Security

2000-12-03 Thread Rob Burne
Hi, I need to find the query that will return all security access permissions. For example if a INSERT has been granted to a particular user, how do I perform the query which will return this result. I know that the \z command returns this, but I need the raw SQL to do it - any ideas please?

[HACKERS] Re: [SQL] Rules with Conditions: Bug, or Misunderstanding

2000-12-03 Thread Tom Lane
Jan Wieck <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> Hm. Perhaps the "cannot update view" test is too strict --- it's not >> bright enough to realize that the two rules together cover all cases, >> so it complains that you *might* be trying to update the view. As the >> code stands, you mu

Re: [SQL] problem with keyword 'old'

2000-12-03 Thread Jan Wieck
Basilis Kladis wrote: [Charset iso-8859-7 unsupported, filtering to ASCII...] > I am ussing Postgresql v. 6.3 in a RedHat Linux system. I try to create a > rule to log the deletes on table 'filter' ussing the following: First of all, the rule system up to version 6.3 is known to be bro

[HACKERS] Re: [SQL] Rules with Conditions: Bug, or Misunderstanding

2000-12-03 Thread Jan Wieck
Tom Lane wrote: > "Joel Burton" <[EMAIL PROTECTED]> writes: > > create rule dev_ins as on update to dev_col_comments where > > old.description isnull do instead insert into pg_description ( objoid, > > description) values (old.att_oid, new.description); > > > create rule dev_upd as on update to de