[BUGS] BUG #5215: Error in PgAdmin

2009-11-26 Thread Walter Willmertinger

The following bug has been logged online:

Bug reference:  5215
Logged by:  Walter Willmertinger
Email address:  will...@gmail.com
PostgreSQL version: 8.4.1
Operating system:   Windows XP Prof.
Description:Error in PgAdmin
Details: 

Since we introduced 8.4.1, we had some failures of our database. The server
remained the same, the application is the same as with our previous 8.3.x
installation.

Error 1:
"Missing ... pg_catalog"
pg_dump not possible
Fixed by "COPY table to FILE ..." for each separate table 
reinstalling postgres, then restored a previous dump and run the output of
the "COPY"

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


[BUGS] BUG #5214: Permission troubles for views

2009-11-26 Thread Nikolay

The following bug has been logged online:

Bug reference:  5214
Logged by:  Nikolay
Email address:  whee...@gmail.com
PostgreSQL version: 8.4.1
Operating system:   Gentoo Linux
Description:Permission troubles for views
Details: 

There is two users in database: user_a and user_b.
user_a is an owner of current schema.

Table "tbl_data":
ALTER TABLE "tbl_data" OWNER TO user_a;
REVOKE SELECT, INSERT, UPDATE, DELETE ON TABLE "tbl_data" FROM user_a;
GRANT REFERENCES, TRIGGER ON TABLE "tbl_data" TO user_a;
GRANT ALL ON TABLE "tbl_data" TO user_b;

Execute query as user_a:
SELECT * FROM "tbl_data"; - permission denied for relation tbl_data. 
This is correct. user_a can't select from  table tbl_data.

Execute query as user_b:
SELECT * FROM "tbl_data"; - returns rows from table.
This is correct. user_b can select from table tbl_data.

View "vw_data":
CREATE VIEW "vw_data" as select * from "tbl_data";
ALTER TABLE "vw_data" OWNER TO user_a;
REVOKE SELECT, INSERT, UPDATE, DELETE ON TABLE "vw_data" FROM user_a;
GRANT ALL ON TABLE "vw_data" TO user_b;

Execute query as user_a:
SELECT * FROM "vw_data"; - permission denied for relation vw_data. This is
correct. 

Execute query as user_b:
SELECT * FROM "vw_data"; - permission denied for relation tbl_data. But
permissions say that user_b can select from tbl_data and from vw_data.

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


Re: [BUGS] BUG #5214: Permission troubles for views

2009-11-26 Thread Tom Lane
"Nikolay"  writes:
> Description:Permission troubles for views

> SELECT * FROM "vw_data"; - permission denied for relation tbl_data. But
> permissions say that user_b can select from tbl_data and from vw_data.

This is not a bug.  The view's reference to tbl_data is controlled by
the permissions of the owner of the view.  If it didn't work like that,
a view couldn't be used as a permissions gateway.

regards, tom lane

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


[BUGS] BUG #5216: pgFouine 1.1 not working correctly, when LC_MESSAGES is "es_ES.UTF-8"

2009-11-26 Thread Henrik Pestano

The following bug has been logged online:

Bug reference:  5216
Logged by:  Henrik Pestano
Email address:  hpest...@uci.cu
PostgreSQL version: 8.4.1
Operating system:   Ubuntu 9.10
Description:pgFouine 1.1 not working correctly, when LC_MESSAGES is
"es_ES.UTF-8"
Details: 

I have a problem with the parameter LC_MESSAGES, where its value is
es_ES.UTF-8 (Spanish), the pgFouine 1.1 not work correctly, because csvlog
generates a column "duración: 0138 ms sentencia: SELECT format_type (oid,
54) as typname pg_type FROM WHERE oid = 1043" and pgFouine not understand
the words "duración" and "sentencia". This information can be in two
columns.

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


Re: [BUGS] psql -1 -f - busted

2009-11-26 Thread Robert Haas
On Thu, Oct 22, 2009 at 2:42 PM, Stephen Frost  wrote:
>  -1 appears to be ignored when '-f -' is set.

I've been bitten by this, too.  It appears that "-f -" is in general
equivalent to not specifying "-f" at all.  In startup.c we have a test
for:

options.action == ACT_FILE && strcmp(options.action_string, "-") != 0

I suppose we could change it to:

options.action == ACT_FILE && (strcmp(options.action_string, "-") != 0
|| pset.notty)

But I sort of think it should just be:

options.action == ACT_FILE

ISTM that if you run psql with "-f -", you shouldn't expect to get an
interactive shell.  Rather, you should expect psql to do whatever it
normally does when given -f somefilename, except using stdin rather
than the file.  After all, you could have left out -f altogether if
you'd wanted the interactive behavior.  But then IJWH.

...Robert

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


Re: [BUGS] psql -1 -f - busted

2009-11-26 Thread Peter Eisentraut
On tor, 2009-11-26 at 22:59 -0500, Robert Haas wrote:
> ISTM that if you run psql with "-f -", you shouldn't expect to get an
> interactive shell.  Rather, you should expect psql to do whatever it
> normally does when given -f somefilename, except using stdin rather
> than the file.  After all, you could have left out -f altogether if
> you'd wanted the interactive behavior.  But then IJWH.

But by that logic, psql < file should also set interactive mode.


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs


Re: [BUGS] BUG #5216: pgFouine 1.1 not working correctly, when LC_MESSAGES is "es_ES.UTF-8"

2009-11-26 Thread Guillaume Smet
Henrik,

On Fri, Nov 27, 2009 at 4:15 AM, Henrik Pestano  wrote:
> I have a problem with the parameter LC_MESSAGES, where its value is
> es_ES.UTF-8 (Spanish), the pgFouine 1.1 not work correctly, because csvlog
> generates a column "duración: 0138 ms sentencia: SELECT format_type (oid,
> 54) as typname pg_type FROM WHERE oid = 1043" and pgFouine not understand
> the words "duración" and "sentencia". This information can be in two
> columns.

Please note that pgsql-bugs mailing list is for PostgreSQL bugs only.

pgFouine doesn't support lc_message other than english. It's usually
considered a good practice to keep your logs in english as it's far
easier to find useful information on the internet with a log message
in english.

I suppose you could use a sed line to translate your logs before
analyzing them with pgFouine.

-- 
Guillaume

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs