Skip site navigation (1) Skip section navigation (2)

Compiling C Functions

From: <tulio(at)pcfacil(dot)com(dot)br>
To: pgsql-docs(at)postgresql(dot)org
Subject: Compiling C Functions
Date: 2000-12-12 22:41:40
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-docs

This is my first time in this list... Sorry by any inconvenience....

I need a TRIGGER thats runs whith POSTGRES permissions. Ill give an ODBC 
connection for programmers that dont need to know the "rules" of my Data 

So, Ill creata an "fake" table, and with a BEFORE INSERT TRIGGER Ill make 
all consistences, and update the REAL tables.

The ODBC users have only INSERT permission on the fake table, and NO RIGHTS 
on the real table.

Ill make VIEWS whith SELECT, UPDATE and DELETE permissions for the ODBC 

By the same way, Ill make TRIGGERS that manager the VIEWS.


ALMOST ALL THIS WORK FINE when the function of the trigger is in PLPGSQL, but 
in this language, the Trigger run with the same ODBD users rights ....

I read that only a "C" function runs with POSTGRES permissions, but all the 
samples I get dont work... I cant even compile them...

Please, anyone could help an "poor brazilian guy" to make this work :-) ?

I appreciate any "C" Function complete samples, including de command line for 
the compiler.

I using a RedHat Linux 6.2 and  Postgresql 7.0.2-2 

Best Regards,

Tulio Oliveira.

pgsql-docs by date

Next:From: Peter EisentrautDate: 2000-12-14 20:25:11
Subject: Re: Operators and Functions
Previous:From: Bruce MomjianDate: 2000-12-12 16:47:51
Subject: Re: Tutorial: chapter 5

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group