public inbox for [email protected]
help / color / mirror / Atom feedFrom: Justin Pryzby <[email protected]>
To: vignesh C <[email protected]>
Cc: Pavel Stehule <[email protected]>
Cc: [email protected]
Subject: Re: proposal: possibility to read dumped table's name from file
Date: Sun, 26 Jul 2020 14:10:06 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <CALDaNm1Qq5Y-BGVNm7HiYieM9cFp3BCJsb5N67XhbBCTzAPRDw@mail.gmail.com>
References: <CAFj8pRDk6EQGpbVO5tOsDvNnw41wmYWS7-w5Ym8gyRjvfoZ64g@mail.gmail.com>
<[email protected]>
<[email protected]>
<CAFj8pRCCJ1vqDREwK41tbRX8k96VSAWFe9uOCCAmLJ8cwJC4Vw@mail.gmail.com>
<CAFj8pRCRQOWLm2LrWcbkcm1Dx7yTuLks1_2VrTJO3PARDNXO3w@mail.gmail.com>
<CALDaNm1iGfcBquWQEhCg5horyMROZc0x3_tQw-v=3hr8MxtOoA@mail.gmail.com>
<CAFj8pRDU-CsvKjxEZ=SvuVjymFSEdS1pgLzxB7RTWSWnnqcLAA@mail.gmail.com>
<CALDaNm3shi3Pco19+VSVRz0zoqFs6_K3UMaFRnpcCqrny08TcQ@mail.gmail.com>
<CAFj8pRBj7rWp6CsRNVAT3wumeFei-VkT4ETWW65rsqgB6F2Mkw@mail.gmail.com>
<CALDaNm1Qq5Y-BGVNm7HiYieM9cFp3BCJsb5N67XhbBCTzAPRDw@mail.gmail.com>
On Sat, Jul 25, 2020 at 06:56:31PM +0530, vignesh C wrote:
> On Tue, Jul 14, 2020 at 12:03 PM Pavel Stehule <[email protected]> wrote:
> >> I meant can this:
> >> printf(_(" --filter=FILENAME read object name filter
> >> expressions from file\n"));
> >> be changed to:
> >> printf(_(" --filter=FILENAME dump objects and data based
> >> on the filter expressions from the filter file\n"));
> >
> > done in today patch
>
> Thanks for fixing the comments.
> Few comments:
> + /* use "-" as symbol for stdin */
> + if (strcmp(filename, "-") != 0)
> + {
> + fp = fopen(filename, "r");
> + if (!fp)
> + fatal("could not open the input file \"%s\": %m",
> + filename);
> + }
> + else
> + fp = stdin;
>
> We could use STDIN itself instead of -, it will be a more easier
> option to understand.
I think "-" is used widely for commandline tools, and STDIN is not (even though
it's commonly used by programmers). For example, since last year, pg_restore
-f - means stdout.
--
Justin
view thread (181+ messages) latest in thread
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: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: proposal: possibility to read dumped table's name from file
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox