Feed Sign in with OpenID OpenID

Simon Willison’s Weblog

grant XXX on * ? (via) PostgreSQL doesn’t have a way to say “this user is allowed to select/update/etc on all tables in database X”. That kind of sucks. UPDATE: This is fixed in PostgreSQL 9, see the comments.

Tagged , , , ,

2 comments

  1. pg 9 (in alpha now) adds a nicer way of doing it: "grant ... on all tables in public;"

    "GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER }
    [,...] | ALL [ PRIVILEGES ] }
    ON { [ TABLE ] table_name [, ...]
    | ALL TABLES IN SCHEMA schema_name [, ...] }
    TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ]"

    http://developer.postgresql.org/pgdocs/postgres/sq l-grant.html

    Tavis Rudd - 16th March 2010 19:27 - #

  2. Oops, that should have been "grant ... on all tables in SCHEMA public"

    Tavis Rudd - 16th March 2010 19:29 - #

Sign in with OpenID

Auto-HTML: Line breaks are preserved; URLs will be converted in to links.

Manual XHTML: Enter your own, valid XHTML. Allowed tags are a, p, blockquote, ul, ol, li, dl, dt, dd, em, strong, dfn, code, q, samp, kbd, var, cite, abbr, acronym, sub, sup, br, pre

A django site