DECLARE
varUnlocked boolean;
BEGIN
varUnlocked:= pg_try_advisory_lock( 783264760123456 ); -- Try to lock function
IF not varUnlocked THEN return NULL; END IF; -- exit if locking is unsucessfull
WRONG QUERY HERE WHICH INTERRUPT EXECUTION
varUnlocked:= pg_advisory_unlock( 783264760123456 ); -- un
Tom Lane wrote:
This code makes the incorrect assumption that the platform will allow the
postgres user to set the permissions using chmod.
Is this something we should do anything about?
IMHO, no. The reason for actually doing the chmod is to verify that we
own the directory. If it fails,
<[EMAIL PROTECTED]> writes:
> EXPECTED: Pg must unlock if function execution failed
This is not a bug; it is the intended and documented behavior
of advisory locks.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your
[EMAIL PROTECTED] wrote:
> DECLARE
> varUnlocked boolean;
> BEGIN
> varUnlocked:= pg_try_advisory_lock( 783264760123456 ); -- Try to lock function
> IF not varUnlocked THEN return NULL; END IF; -- exit if locking is
> unsucessfull
>
> WRONG QUERY HERE WHICH INTERRUPT EXECUTION
>
> varUnlocked: