Re: pgcrypto: PGP armor headers

Поиск
Список
Период
Сортировка
Искать
От
Marko Tiikkaja
Тема
Re: pgcrypto: PGP armor headers
Дата
Msg-id
542ACEC3.5030004@joh.to
Ответ на
Re: pgcrypto: PGP armor headers (Heikki Linnakangas)
Список
Дерево обсуждения
pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Alvaro Herrera <alvherre@2ndquadrant.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Marko Tiikkaja <marko@joh.to>
Re: pgcrypto: PGP armor headers Heikki Linnakangas <hlinnakangas@vmware.com>
Re: pgcrypto: PGP armor headers Joel Jacobson <joel@trustly.com>
Re: pgcrypto: PGP armor headers Jeff Janes <jeff.janes@gmail.com>
On 9/30/14 5:17 PM, Heikki Linnakangas wrote:
> I'm actually now leaning towards providing just a single function,
> pgp_armor_headers(text, key OUT text, value OUT text), which returns all
> the keys and values. That gives maximum flexibility, and leaves it up to
> the user to decide what to do with duplicate keys. It's pretty easy to
> use that to extract just a single header, too:
>
> 
>
> What do you think? Attached patch implements that, but the docs and
> regression tests now need adjustment.

(You forgot the patch, but I can imagine what it would have been.)

I'm not exactly sure to be honest.  I would personally like to see a 
simple function for extracting a single header value in a scalar context 
without having to deal with all the pain of SRFs, multiple matches and 
no matches.  Sure, that got a lot better in 9.3 with LATERAL but it's 
still way inferior to pgp_armor_header().

I can also see why someone would argue that I should just create the 
function myself and that it doesn't have to be shipped with postgres. 
But on the other hand, this is already an extension one has to 
explicitly go and CREATE, and that considered one more function probably 
wouldn't hurt too much.

But either way I won't be unhappy, so it's up to you (and/or other 
members of the community) to decide this one.


.marko


В списке pgsql-hackers по дате отправления
От: Simon Riggs
Дата:
От: Stephen Frost
Дата:
FAQ