Re: how to read bytea contents by using pgsql scripts

Поиск
Список
Период
Сортировка
От Christoph Haller
Тема Re: how to read bytea contents by using pgsql scripts
Дата
Msg-id 200311241026.LAA05684@rodos
обсуждение исходный текст
Ответ на how to read bytea contents by using pgsql scripts  ("vijaykumar M" <m_vijaykumar@hotmail.com>)
Список pgsql-sql
> 
> Hi All,
>   Is their any way to read the bytea contents by using pgsql script.
> 
> Thanks & regards
> Vijay
> 
> _________________________________________________________________
> 
Not sure if that's what you are asking for but you can do e.g. 

$PGSQLD/bin/psql -d <your-dbase-name> -f ./query2.txt >  ./query2.res 

./query2.txt has something like 
select * from bytea_tab ; 

then you'll find all non-printables in  ./query2.res 
properly escaped as octets as shown in Data Types - Binary Strings. 

HTH 

Regards, Christoph 



В списке pgsql-sql по дате отправления:

Предыдущее
От: "Matthew Lunnon"
Дата:
Сообщение: Re: increment int value in subset of rows?
Следующее
От: "vijaykumar M"
Дата:
Сообщение: Re: how to read bytea contents by using pgsql scripts