converting to hex

From: Jamie Deppeler <jamie(at)doitonce(dot)net(dot)au>
To: pgsql-general(at)postgresql(dot)org
Subject: converting to hex
Date: 2005-04-07 00:37:23
Message-ID: 425480C3.2070506@doitonce.net.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I am trying to write a function that will allow a postgres to convert a
text string into a hex value but there doesnt seem a function to do it,
only one i could find is to_hex(number) example of what i have done is

update table1
Set field2 = encode((select md5('field1')),'hex')
where new."primary" = "primary";

any help would be greatfully received

Browse pgsql-general by date

  From Date Subject
Next Message Chris Smith 2005-04-07 00:58:16 using limit with delete
Previous Message Hervé Piedvache 2005-04-06 23:42:33 Re: Big trouble with memory !!