Re: Help with ODBC problem - Mailing list pgsql-odbc

From Dave Page
Subject Re: Help with ODBC problem
Date
Msg-id 71FEDEE1-A40E-4A1B-BC9E-816B4381BC7D@mimectl
Whole thread Raw
In response to Re: Help with ODBC problem  ("Chris Hoover" <revoohc@sermonaudio.com>)
List pgsql-odbc


From: Chris Hoover
Sent: Fri 6/4/2004 9:39 PM
To: Jeff Eckermann
Cc: pgsql-odbc@postgresql.org
Subject: Re: [ODBC] Help with ODBC problem
Ok, I created a new schema and put my view into it giving my reporting 
group access to this view only.  I also set the search_path in the odbc 
driver and as an alter user, but I am still seeing a full db catalog 
when I connect to my db via odbc. (link trying to link a table in Access).

Any further ideas?  I really need the end users to only see the specific 
views/tables I grant them access to when they are an area where they are 
able to choose tables/views to view.
I think you'll be out of luck. iirc, when an app asks the ODBC driver what tables exist it just queries pg_class without regard to visibility rules imposed by the schema search path. Technically this is correct, because even without a schema being in the path, a user can still reference it using scheme.table notation.
I suspect your best option would be to hack PGAPI_Tables() in info.c if you absolutely must stop users seeing tables, though the best be would probably be to simply leave the driver as it is, let the users see the tables, but deny them any direct access to them.
Regards, Dave

pgsql-odbc by date:

Previous
From: Karol Szkudlarek
Date:
Subject: psqlodbc ready for amd64?!
Next
From: Håkon Clausen
Date:
Subject: 7.4 backend protocol