pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter_e@gmx.net>
To: Peter Wang <pwang@voyence.com>
To: pgsql-sql@postgresql.org
Subject: Re: BYTEA output presentation
Date: Fri, 16 Jul 2004 22:48:43 +0200
Message-ID: <200407162248.43228.peter_e@gmx.net> (raw)
In-Reply-To: <3AE153EDD5CA7B4CBA26FCDA1CBA6478403412@hermes.internal.powerupnetworks.com>
References: <3AE153EDD5CA7B4CBA26FCDA1CBA6478403412@hermes.internal.powerupnetworks.com>

Peter Wang wrote:
> The BYTEA data look like "/031/024/001/003?/022/....".
> How can I use some PostgreSQL function to remove "/" when I use
> select statement ? What type of format is the BYTEA datatype? Can I
> output it to hexadecimal or octal format ? If you can, how ? Or do
> you know any third party tool or script which can output the
> hexadecimal or octal format for PostgreSQL's BYTEA datatype ? Your
> help is appreciated. Thank you.

libpq has functions to deal with bytea data: 
http://www.postgresql.org/docs/7.4/static/libpq-exec.html#LIBPQ-EXEC-ESCAPE-BYTEA

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/




view thread (2+ messages)

Message-ID: <200407162248.43228.peter_e@gmx.net>
Permalink:  ../200407162248.43228.peter_e@gmx.net/
Also on:    postgresql.org/message-id/200407162248.43228.peter_e@gmx.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: peter_e@gmx.net, pwang@voyence.com
  Subject: Re: BYTEA output presentation
  In-Reply-To: <200407162248.43228.peter_e@gmx.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox