[GENERAL] pgcrypto functions fail for asymmetric encryption/decryption

2007-11-29 Thread Stefan Niantschur
Hi, I have a table with userids and public keys. I want to write a function which does a select and returns the result pgp encrypted. However, I have some problems: SELECT encode(decode((SELECT ens_pubkey FROM ens_user)::text,'escape'),'escape'::text)::text; -> returns the public key, => ok SELE

Re: [GENERAL] pgcrypto functions fail for asymmetric encryption/decryption

2007-12-03 Thread Stefan Niantschur
Am Fri, 30 Nov 2007 12:06:37 +0200 schrieb "Marko Kreen" <[EMAIL PROTECTED]>: Hi Marko, first of all, thank you for your help. Please find my answers below: > On 11/29/07, Stefan Niantschur <[EMAIL PROTECTED]> wrote: > > I have a table with userids and

Re: [GENERAL] pgcrypto functions fail for asymmetric encryption/decryption

2007-12-03 Thread Stefan Niantschur
x27;::text); Thank you very much for your help. > On 12/3/07, Stefan Niantschur <[EMAIL PROTECTED]> wrote: > > > Or at least send key parameters (gpg --list-keys output). > > > > pub 1024D/0476AD06 2007-11-27 [verfällt: 2008-11-26] > > uid Test User (Probebenutze

Re: [GENERAL] pgcrypto functions fail for asymmetric encryption/decryption

2007-12-03 Thread Stefan Niantschur
Am Montag, 3. Dezember 2007 schrieben Sie: > On 12/3/07, Stefan Niantschur <[EMAIL PROTECTED]> wrote: > > I finally made it. I created a brand-new key, reworked the query and > > voila. > > > > It seems that the GnuPG key has to be created with > > paramter

[GENERAL] How to return a large String with C

2008-02-17 Thread Stefan Niantschur
Hi all, I want to write a function in C which retrieves a large string from a table, does some work on it and returns the result to the surrounding SELECT. (e.g. SELECT my_c_func(text);) So far I have been successfully doing calls to SPI, select the data from the table and return it. However,

Re: [GENERAL] How to return a large String with C

2008-02-17 Thread Stefan Niantschur
Am Sun, 17 Feb 2008 09:17:08 -0500 schrieb Tom Lane <[EMAIL PROTECTED]>: > Stefan Niantschur <[EMAIL PROTECTED]> writes: > > So far I have been successfully doing calls to SPI, select the data > > from the table and return it. However, this works only with string >

Re: [GENERAL] How to return a large String with C

2008-02-18 Thread Stefan Niantschur
Am Sun, 17 Feb 2008 14:28:18 -0500 schrieb Tom Lane <[EMAIL PROTECTED]>: > Stefan Niantschur <[EMAIL PROTECTED]> writes: > > Am Sun, 17 Feb 2008 09:17:08 -0500 > > schrieb Tom Lane <[EMAIL PROTECTED]>: > >> Hardly surprising when you're printing t

Re: [GENERAL] How to return a large String with C (solved)

2008-02-18 Thread Stefan Niantschur
Am Sun, 17 Feb 2008 14:28:18 -0500 schrieb Tom Lane <[EMAIL PROTECTED]>: > Stefan Niantschur <[EMAIL PROTECTED]> writes: > > Am Sun, 17 Feb 2008 09:17:08 -0500 > > schrieb Tom Lane <[EMAIL PROTECTED]>: > >> Hardly surprising when you're printing t

Re: [GENERAL] How to return a large String with C

2008-02-18 Thread Stefan Niantschur
Am Mon, 18 Feb 2008 14:15:14 -0500 schrieb Tom Lane <[EMAIL PROTECTED]>: > Stefan Niantschur <[EMAIL PROTECTED]> writes: > > Please find below the most recent code snippet. It is mainly based > > on examples from the pg documentation: > > ---8<