[SQL] Execute permissions for stored functions

2004-01-18 Thread Paul Hart
Hi all,

From what I've seen in the archives, questions like this have kind of 
been answered in the past, but I was wondering if there have been any 
changes in this area, or if anyone has good ideas on how to do what I'm 
about to ask :)

In RDBMSs such as Oracle, stored PL/SQL functions run with the 
permissions of the user that creates the function. Users who are given 
EXECUTE privileges then call the function with the permissions of the 
creator of the function.

Is this how things work with PL/pgSQL in PostgreSQL? From my 
understanding, the answer is 'no.' If the answer really is 'no,' then 
how do I achieve the same thing?

The main benefit for this is in security - I have a dynamic web 
application that requires (a lot of) access to a PostgreSQL database. I 
want to make sure that the user doesn't have direct access to change 
the content of tables, but rather to alter their contents, in 
predetermined ways, through a set of functions. It's another layer that 
protects against hacking, and because my project involves a lot of 
monetary transactions (and database transactions), I want to reduce my 
potential for malicious abuse.

Many thanks in advance for you help,

Paul

smime.p7s
Description: S/MIME cryptographic signature


Re: [SQL] Help! Error with postgresql!

2004-02-01 Thread Paul Hart
Would you mind telling us what's in your SQL file? it seems that 
there's a problem in it.

On 28 Jan 2004, at 05:12, [EMAIL PROTECTED] wrote:

Hello,
I have problem when i execute the .sql file in my psql command prompt.
The error code is below:
pylori=# \i log-clinique.sql
CREATE
psql:log-clinique.sql:100: ERROR:  parser: parse error at or near ".3"
psql:log-clinique.sql:107: ERROR:  parser: parse error at or near ".3"
psql:log-clinique.sql:113: ERROR:  parser: parse error at or near ".3"
 
pylori=# \i trigger-clinique.sql
" does not exist in the system catalog.
createlang: external error
DROP
CREATE
DROP
CREATE
pylori=#
I hope some of you can help me with this.
Thank a lot,
raingsey 
---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
   (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])