Re: Request for help on retrieving binary data from bytea column using ODBC calls - Mailing list pgsql-odbc

From Hiroshi Inoue
Subject Re: Request for help on retrieving binary data from bytea column using ODBC calls
Date
Msg-id 4F48058E.8010509@tpf.co.jp
Whole thread Raw
In response to Re: Request for help on retrieving binary data from bytea column using ODBC calls  (Ganesh Borse <bganesh05@gmail.com>)
List pgsql-odbc
(2012/02/24 18:56), Ganesh Borse wrote:
> Hi,
>
> I used the steps same as outlined below:
>
>      xxd -p /home/user/myimage.png | tr -d '\n' > /tmp/image.hex
>      DELETE FROM hexdump; -- hexdump table is: -- CREATE TABLE hexdump
> (hex text);
>      COPY hexdump FROM '/tmp/image.hex';
>      UPDATE users SET image= (SELECT decode(hex, 'hex') FROM hexdump
> LIMIT 1) where id=15489
>
> Is this the correct way of inserting binary data into bytea column?
>
> When I fetch a small part of this column, I get output as below:
>
>     select substring(smallblob,0,64) from longdata where blobi d=1;
>
>   \xd0cf11e0a1b11ae1000000000000000000000000000000003b000300feff09000600000000000
00000000000010000006a0000000000000000100000670000(1 row) 

Looks OK to me.
Could you send me directly the Mylog output of the simple test case?

regards,
Hiroshi Inoue

pgsql-odbc by date:

Previous
From: Ganesh Borse
Date:
Subject: Re: Request for help on retrieving binary data from bytea column using ODBC calls
Next
From: Ganesh Borse
Date:
Subject: Re: Request for help on retrieving binary data from bytea column using ODBC calls