psql latex and newlines

Поиск
Список
Период
Сортировка
От Wim Bertels
Тема psql latex and newlines
Дата
Msg-id 1323713712.2454.14.camel@zwerfkat
обсуждение исходный текст
Ответы Re: psql latex and newlines  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-general
Hallo,

psql latex output format needs to differentiate between a newline and a
tabularnewline.

the problem arises when u have a field value that contains a newline
character, when this field is not the first column, then all the data
after this newline comes in the first column..

u can try this out, writing a function or table,
and then add 'enters' or newline in the COMMENT on this function or
table.

the \pset recordsep doesn't solve this, since the mistakes take place
within the same record.

so first:
make some function of table
\o tofile
\pset format latex
\df+ \dt+ or ..

eg:
-- latex generated: with the wrong layout

\begin{tabular}{|c|l|}

\hline

\multicolumn{2}{|c|}{\textit{Record 1}} \\

\hline

entry1\_test & test \\

..

out\_result & TABLE(out\_field1 integer,\\ out\_field2 character
varying,\\ out\_del boolean) \\
out\_description & This function deletes a record\\ given the
following .. foreign\_key\_violation.\\ \\

\hline

Compared with text output, right layout:
-[ RECORD1 ]------------+--------------------------------------------------------------
entry1_test             | test
..

out_resultdatatypes     | TABLE(out_field1 integer,
                        :  out_field2 character varying,
                        :  out_del boolean)
out_description         | This function deletes a record
                        :         given the following ..
..
                        :         .. foreign_key_violation.


mvg,
Wim



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

Предыдущее
От: Wojciech Strzałka
Дата:
Сообщение: Re: Problem installing PG9.1 using yum
Следующее
От: Scot Kreienkamp
Дата:
Сообщение: initdb with lc-collate=C