Re: Markdown format output for psql, design notes

From: Lætitia Avrot <laetitia(dot)avrot(at)gmail(dot)com>
To: daniel(at)manitou-mail(dot)org
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Markdown format output for psql, design notes
Date: 2018-11-30 14:47:23
Message-ID: CAB_COdibhvhRJef8guQnaen7ug7x8afrzsmnh_pa=qvcdJ58Hg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

No I meant independently of the screen, if there's an LF character
> in a cell. Or a '|' character, since that's the same problem: an
> element of structure happening to be in the contents.
> The specs mentioned upthread don't seem to give any indication
> about that being supported.
>
> i've given a list of characters that needs escaping as stated in the
Markdown Extra doc and `|` is certainly one of this.

For LF caracter, I'm totally ok with the fact that it will break the
markdown output and my answer to that is "KISS". I don't want to handle
that case. Markdown Extra obviously decided that there was no such thing as
a multiline row.

> Say we have:
> SELECT E'foo\nbar' as "Header1", 'foo|bar' as "Header2"
>
> If the markdown output was produced for the sole purpose of being
> converted to HTML in the end, which is often the case, it would work
> to use HTML entities in the output
>
> I don't use Markdown to create a HTML output. I use it to generate pdf for
my customers.

But as Vik said earlier, maybe it's not worth it to provide a markdown
output as pandoc can generate the markdown from the HTML output.
And if you need the markdown output to generate HTML why don't you use the
HTML output ?

Cheers,

Lætitia
--
*Think! Do you really need to print this email ? *
*There is no Planet B.*

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2018-11-30 14:54:12 Re: Query with high planning time at version 11.1 compared versions 10.5 and 11.0
Previous Message Dmitry Dolgov 2018-11-30 14:42:34 Re: pgbench doc fix