Re: Database privileges

Поиск
Список
Период
Сортировка
От Day, David
Тема Re: Database privileges
Дата
Msg-id 401084E5E73F4241A44F3C9E6FD79428A14D676E@exch-01
обсуждение исходный текст
Ответ на Database privileges  (Diogo Martinez <diogo.martinez@gmail.com>)
Список pgsql-novice

Probably the problem is your pg_hba.conf file which can filter access by IP address.

Your JDBC connection is perhaps via a hostname ( not localhost ) and your psql attachment was via local host.

A default installation only allows for localhost access.

 

e,g,

 

psql –h localhost  newdb    vs psql –h hostname

 

if one works and the other does not then adjust your pg_hba.conf file to allow access from other then localhost interface.

 

 

Rgds

 

 

Dave

 

From: pgsql-novice-owner@postgresql.org [mailto:pgsql-novice-owner@postgresql.org] On Behalf Of Diogo Martinez
Sent: Friday, April 19, 2013 12:22 PM
To: pgsql-novice@postgresql.org
Subject: [NOVICE] Database privileges

 

Hi,

 

I've installed PostgreSQL 9.2.4, created a new database, created 1 new role and 1 table called t_test.

When I connect using psql with my new role and do a simple query (select * from t_test), it works fine, but when I connect using JDBC using the same role, I get a no privileges exception.

 

Can anybody help me, please?

 

Thanks,

Diogo

В списке pgsql-novice по дате отправления:

Предыдущее
От: kobolds
Дата:
Сообщение: create database with owner
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Database privileges