Re: [GENERAL] column names query

Поиск
Список
Период
Сортировка
От hamann.w@t-online.de
Тема Re: [GENERAL] column names query
Дата
Msg-id wolfgang-1170907151749.A0330521@noten19.local
обсуждение исходный текст
Ответ на Re: [GENERAL] column names query  (Francisco Olarte <folarte@peoplecall.com>)
Ответы Re: [GENERAL] column names query  (Francisco Olarte <folarte@peoplecall.com>)
Список pgsql-general

>> On Thu, Sep 7, 2017 at 9:18 AM,  <hamann.w@t-online.de> wrote:
>> > is there a simple way to retrieve column names from a query - basically the way psql adds
>> > column headings when I do a select?
>>
>> How do you do the query? I mean, JDBC, PERL? After all psql is just a
>> C program doing a query using libpq and can do it, we may provide some
>> useful info if you show yours first.
>>
>> Francisco Olarte.

Hi,

I imagine this situation:
I start working on a query... when I am happy with the result, I see a table (with headers) in psql.
Now I can do
\copy (select .... my query here) to /tmp/testfile1
I would like to do something like
\copy (select heading(select .... my query here)) to /tmp/heading_testfile1

Best regards
Wolfgang Hamann




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

Предыдущее
От: milist ujang
Дата:
Сообщение: Re: [GENERAL] BDR, wal segment has been removed, is it possible move forward?
Следующее
От: hamann.w@t-online.de
Дата:
Сообщение: Re: [GENERAL] column names query