Re: Export binary data - PostgreSQL 9.2

From: Abdul Sayeed <abdulsayeed24(at)gmail(dot)com>
To: "drum(dot)lucas(at)gmail(dot)com" <drum(dot)lucas(at)gmail(dot)com>
Cc: Steve Crawford <scrawford(at)pinpointresearch(dot)com>, Postgres General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Export binary data - PostgreSQL 9.2
Date: 2016-03-03 01:50:57
Message-ID: CAHb=FFxMDRJCk83Cghd_QZM6btcwN6rPD_3w2Ssr0bTuK=CZzg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

You can use pg_dump with -t and -Fc option to take dump of a table in
compressed format.

$PGBIN/pg_dump -t <TABLE_NAME> -Fc -d <DATABASE_NAME> -f /tmp/table.dmp

For more information you can refer below link:

http://www.postgresql.org/docs/9.2/static/app-pgdump.html

Hope this would help.

On Thu, Mar 3, 2016 at 1:21 AM, drum(dot)lucas(at)gmail(dot)com <drum(dot)lucas(at)gmail(dot)com>
wrote:

>
>
> On 29 February 2016 at 06:31, Steve Crawford <
> scrawford(at)pinpointresearch(dot)com> wrote:
>
>> What exactly are you trying to do? Dump/backup your data (e.g. pg_dump)?
>> Read binary data from a table? If so, what field type (bytea, blob, ...)?
>> Export to where?
>>
>> Cheers,
>> Steve
>>
>>
>> On Sun, Feb 28, 2016 at 9:12 AM, drum(dot)lucas(at)gmail(dot)com <
>> drum(dot)lucas(at)gmail(dot)com> wrote:
>>
>>> Hi all,
>>>
>>>
>>> Which command would be to export the binary data for a table?
>>>
>>> I was unable to find it...
>>>
>>> Thanks
>>>
>>
>>
>
> Have just used the COPY .... WITH Binary
>
> Thank you.
>

--
Thanks & Regards,
Abdul Sayeed
PostgreSQL DBA
Postgres Professional Certified
EnterpriseDB Corp
Skype: abdul.sayeed24

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Premsun Choltanwanich 2016-03-03 01:52:51 Re: could not migrate 8.0.13 database with large object data to 9.5.1
Previous Message John R Pierce 2016-03-03 00:53:30 Re: CStringGetTextDatum and other conversions in server-side code