How hard would it be to support LIKE in return declaration of generic record function calls ?
От
Hannu Krosing
Тема
How hard would it be to support LIKE in return declaration of
generic record function calls ?
Дата
Msg-id
1335958834.3106.454.camel@hvost
Список
Дерево обсуждения
How hard would it be to support LIKE in return declaration of
generic record function calls ? Hannu Krosing <hannu@2ndQuadrant.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Peter Eisentraut <peter_e@gmx.net>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Merlin Moncure <mmoncure@gmail.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Hannu Krosing <hannu@2ndQuadrant.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Pavel Stehule <pavel.stehule@gmail.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Merlin Moncure <mmoncure@gmail.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Pavel Stehule <pavel.stehule@gmail.com>
Re: How hard would it be to support LIKE in return declaration
of generic record function calls ? Andrew Dunstan <andrew@dunslane.net>
Re: How hard would it be to support LIKE in return declaration of generic record function calls ? Tom Lane <tgl@sss.pgh.pa.us>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Pavel Stehule <pavel.stehule@gmail.com>
Re: How hard would it be to support LIKE in return declaration of generic record function calls ? Tom Lane <tgl@sss.pgh.pa.us>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Pavel Stehule <pavel.stehule@gmail.com>
Re: How hard would it be to support LIKE in return declaration of generic record function calls ? Tom Lane <tgl@sss.pgh.pa.us>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Merlin Moncure <mmoncure@gmail.com>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Merlin Moncure <mmoncure@gmail.com>
Re: How hard would it be to support LIKE in return declaration
of generic record function calls ? Andrew Dunstan <andrew@dunslane.net>
Re: How hard would it be to support LIKE in return
declaration of generic record function calls ? Merlin Moncure <mmoncure@gmail.com>
Hi Hackers How hard would it be to add support for LIKE syntax, similar to table def in field list declaration for generic record functions What I'dd like to be able to do is to have a generic json_to_record function CREATE OR REPLACE RECORD json_to_record(json) RETURNS RECORD AS $$ ... $$ LANGUAGE ... ; and then be able to call it like this insert into test2 select * from json_to_record(jrec json) as (like test2); ERROR: syntax error at or near "like" instead of explicitly spelling out the structure of table test2 in the AS part. insert into test2 select * from json_to_record(jrec json) as (id int, data2 test, tstamp timestamp); INSERT 0 1 PS. As a pie-in-the-sky wish I'd prefer of course even simpler syntax of insert into test2 json_to_record(jrec json); or at least insert into test2 json_to_record(jrec json)::test2; :) - ------- Hannu Krosing PostgreSQL Unlimited Scalability and Performance Consultant 2ndQuadrant Nordic PG Admin Book: http://www.2ndQuadrant.com/books/
В списке pgsql-hackers по дате отправления