Re: Automate copy - Postgres 9.2

From: Patrick B <patrickbakerbr(at)gmail(dot)com>
To: John R Pierce <pierce(at)hogranch(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Automate copy - Postgres 9.2
Date: 2016-06-09 01:47:12
Message-ID: CAJNY3iuY46OsoopmE-2-0POqiBNAkD31NcYXKVF5Q+Gt0UD12g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

2016-06-09 13:15 GMT+12:00 John R Pierce <pierce(at)hogranch(dot)com>:

> On 6/8/2016 5:46 PM, Patrick B wrote:
>
> Single id as you show, a range of numbers or an array of numbers?
>
>
> select function(21);
>
> Where 21 = Number of ids
>
>
> how do you get the specific ID's from "21" ?
>
>
>
21 is the number of IDS that I wanna perform that COPY command....

twenty one times this sql:

COPY

> COPY
> (SELECT * FROM backup_table WHERE id = 1112 AND status = 1)
> TO '/var/lib/pgsql/1112.sql';
> COPY
> (SELECT * FROM backup_table WHERE id = 1113 AND status = 1)
> TO '/var/lib/pgsql/1113.sql';

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message John R Pierce 2016-06-09 01:58:35 Re: Automate copy - Postgres 9.2
Previous Message Michael Paquier 2016-06-09 01:43:53 Re: Can SET_VARSIZE cause a memory leak?