Re: Dynamic PL/pgSQL select query: value association propblem - Mailing list pgsql-general

From Thiemo Kellner
Subject Re: Dynamic PL/pgSQL select query: value association propblem
Date
Msg-id f15c54a2-7299-9684-e7be-ffde281b8481@gelassene-pferde.biz
Whole thread Raw
In response to Re: Dynamic PL/pgSQL select query: value association propblem  ("Thiemo Kellner, NHC Barhufpflege"<thiemo.kellner@gelassene-pferde.biz>)
List pgsql-general
On 02/16/18 14:47, Thiemo Kellner, NHC Barhufpflege wrote:
> Thanks for answering.
> 
> Zitat von Pavel Stehule <pavel.stehule@gmail.com>:
> 
>> Why you don't create query like
>>
>> EXECUTE 'SELECT xxx FROM TAB WHERE A = $1.x AND B = $1.y'  USING NEW;
> 
> I shall try. This would be the direct way, but I doubt the placeholder 
> $1 can be a record.

It's terrific! This works! :-) :-) :-)

-- 
+49 (0)1578-772 37 37
+41 (0)78 947 36 21
SIP/iptel.org: thiemo.kellner
Öffentlicher PGP-Schlüssel:
http://pgp.mit.edu/pks/lookup?op=get&search=0xCA167FB0E717AFFC

Attachment

pgsql-general by date:

Previous
From: Melvin Davidson
Date:
Subject: Re: gathering ownership and grant permissions
Next
From: Olegs Jeremejevs
Date:
Subject: Rationale for PUBLIC having CREATE and USAGE privileges on the schema"public" by default