Re: PostGIS dropgeometrycolumn function (Was: Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function )

2004-02-03 Thread Tom Lane
Paul Ramsey <[EMAIL PROTECTED]> writes: > Oh, now I remember. The deal was not views, it was triggers. Oh, okay. You're right, we don't do triggers on system tables. But couldn't you combine a view on the system tables with storage of additional data outside? regards, to

Re: PostGIS dropgeometrycolumn function (Was: Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function )

2004-02-03 Thread Tom Lane
Paul Ramsey <[EMAIL PROTECTED]> writes: > In an idea world though, we would construct the thing as a view, so > that when you did a CREATE TABLE that included a geometry type, you > would automatically get a row in geometry_columns. That requires a view > on system tables though, and that just d

Re: PostGIS dropgeometrycolumn function (Was: Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function )

2004-01-20 Thread Tom Lane
"Marc G. Fournier" <[EMAIL PROTECTED]> writes: > So, if we replace that with: > ALTER TABLE table_name ALTER column_name DROP NOT NULL; ? > should be good to go? still not as clean as doing the straight DROP > COLUMN, but its a fast fix ... Yeah, that's what I'd do until the PostGIS guys can reth

Re: PostGIS dropgeometrycolumn function (Was: Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function )

2004-01-20 Thread Tom Lane
"Marc G. Fournier" <[EMAIL PROTECTED]> writes: > On Mon, 19 Jan 2004, Tom Lane wrote: >> in particular, what SQL command is it trying to execute when it chokes? > The function is executing: > EXECUTE ''update pg_attribute set attnotnull = false from pg_class where > pg_att

PostGIS dropgeometrycolumn function (Was: Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function )

2004-01-20 Thread Marc G. Fournier
On Mon, 19 Jan 2004, Tom Lane wrote: > "Marc G. Fournier" <[EMAIL PROTECTED]> writes: > > Just had a client point this out to me, and am wondering if its supposed > > to happen: > > > 420_test=> select > > dropgeometrycolumn('420_test','lroadline61','roads61_geom'); > > ERROR: permission denied f

Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function

2004-01-19 Thread Christopher Kings-Lynne
420_test=> select dropgeometrycolumn('420_test','lroadline61','roads61_geom'); ERROR: permission denied for relation pg_attribute CONTEXT: PL/pgSQL function "dropgeometrycolumn" line 19 at execute statement the database was created as: CREATE DATABASE WITH OWNER = and I'm connected to the da

Re: [HACKERS] [7.4] "permissions problem" with pl/pgsql function

2004-01-19 Thread Tom Lane
"Marc G. Fournier" <[EMAIL PROTECTED]> writes: > Just had a client point this out to me, and am wondering if its supposed > to happen: > 420_test=> select > dropgeometrycolumn('420_test','lroadline61','roads61_geom'); > ERROR: permission denied for relation pg_attribute > CONTEXT: PL/pgSQL funct