Re: Returning bytea* from a C function

From: Joe Conway <mail(at)joeconway(dot)com>
To: busby(at)pnts(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Returning bytea* from a C function
Date: 2002-07-09 16:36:47
Message-ID: 3D2B111F.5090506@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

David Busby wrote:
> List,
> I'm trying to build a function for PostgreSQL that allows me to
> create a new UUID for data in my datbase. Has anyone had experience
> with this one? I was going to store it as a bytea datatype, would a
> char(32) be better? Any Ideas?
>

If your table will be very large, using bytea will save a fair amount of
space. Other possibilities are to encode the data into base64 or hex and
store in a TEXT (or VARCHAR or CHAR()) field.

Joe

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Stephan Szabo 2002-07-09 16:48:38 Re: update problem?
Previous Message Joe Conway 2002-07-09 16:33:28 Re: Creating a Function with C that returns bytea