From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> |
Cc: | Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pg_database datistemplate |
Date: | 2002-10-24 20:39:51 |
Message-ID: | 14393.1035491991@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> writes:
> In the docs it is mentioned for datistemplate that
> "If true then this database can be used in the "TEMPLATE" clause of
> CREATE DATABASE to create the new database as a clone of this one."
Right.
> However, one can create a database using as template another DB that has
> datistemplate set to false.
Only if one is owner of the source database (or superuser).
> In this situation, what is the point of having datistemplate?
Effectively, it's a "grant right to copy" flag.
Now that we have per-database ACLs, we should probably replace
datistemplate with an access right; instead of setting it you'd
do something like GRANT COPY ON DATABASE foo TO PUBLIC.
(We'd also talked about replacing datallowconn with an access right,
although that is more likely to break existing apps, since a fair
number of them look at datallowconn.)
Too late for 7.3 though ...
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | cbbrowne | 2002-10-24 21:12:14 | Re: Hot Backup |
Previous Message | Hadley Willan | 2002-10-24 20:39:12 | Re: Hot Backup |