Re: [HACKERS] proposal: psql command \graw

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: [HACKERS] proposal: psql command \graw
Дата
Msg-id alpine.DEB.2.20.1711100805070.28452@lancre
обсуждение исходный текст
Ответ на Re: [HACKERS] proposal: psql command \graw  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: [HACKERS] proposal: psql command \graw
Список pgsql-hackers
>> ISTM that you can remove "force_column_header" and just set "tuple_only"
>> to what you need, that is you do not need to change anything in function
>> "print_unaligned_text".
>
> Last point is not possible - I would not to break original tuple only mode.

Hmmm... I do not understand. I can see only one use of force_column_header 
in the function:
 -               if (!opt_tuples_only) +               if (!opt_tuples_only || opt_force_column_header)

So I would basically suggest to do:
 my_popt.topt.tuples_only = !pset.g_raw_header;

in the driver. Looking at the detailed code in that function, probably you 
need to set start_table to on when headers are needed and stop_table to 
off for the raw mode anyway?

Maybe I'm missing something, but it looks that it could be made to work 
without adding another boolean.

-- 
Fabien.


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

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

Предыдущее
От: Kyotaro HORIGUCHI
Дата:
Сообщение: Re: [HACKERS] path toward faster partition pruning
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: [HACKERS] proposal: psql command \graw