Re: Pgcrypto install (I've tried multiple ways)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "David Patricola" <david(dot)patricola(at)jefferson(dot)edu>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Pgcrypto install (I've tried multiple ways)
Date: 2011-01-27 23:34:04
Message-ID: 9064.1296171244@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

"David Patricola" <david(dot)patricola(at)jefferson(dot)edu> writes:
> Actually, what is bytea in terms of type, or rather, what types of database
> fields will this work with? The field I'm calling from the table is varchar
> (the encrypt function worked find for this).

bytea is for arbitrary byte strings, ie, non-textual data. Typically
you'd store the output of encrypt() (which yields bytea) in the database
and then apply decrypt() to that. Not sure what you're trying to do
above.

BTW, according to the pgcrypto man page, use of the PGP functions is
preferred over directly using encrypt/decrypt.

regards, tom lane

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message David Patricola 2011-01-28 00:06:43 Re: Pgcrypto install (I've tried multiple ways)
Previous Message David Patricola 2011-01-27 23:22:49 Re: Pgcrypto install (I've tried multiple ways)