Re: [patch] Proposal for \crosstabview in psql

From: "Daniel Verite" <daniel(at)manitou-mail(dot)org>
To: "Alvaro Herrera" <alvherre(at)2ndquadrant(dot)com>
Cc: "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>,"Robert Haas" <robertmhaas(at)gmail(dot)com>,"Dean Rasheed" <dean(dot)a(dot)rasheed(at)gmail(dot)com>,"Andres Freund" <andres(at)anarazel(dot)de>,"Teodor Sigaev" <teodor(at)sigaev(dot)ru>,"PostgreSQL Hackers" <pgsql-hackers(at)postgresql(dot)org>,"Jim Nasby" <Jim(dot)Nasby(at)bluetreble(dot)com>
Subject: Re: [patch] Proposal for \crosstabview in psql
Date: 2016-04-08 10:29:49
Message-ID: df155e9e-8ab0-44cf-b91b-048a1025cde6@mm
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Alvaro Herrera wrote:

> I messed with that code some more, as it looked unnecessarily
> complicated; please see attached and verify that it still behaves
> sanely. This needs those regression tests you promised. I tested a few
> cases and it seems good to me.

I've fixed a couple things over v16:
- avoid passing every cell through psprintf, which happened due
to cont.cells being pre-initialized to empty strings.
- adjusted the loop freeing allocated_cells

and added the regression tests.

Attached is the diff over v16, tested with make check and valgrind.

Best regards,
Daniel Vérité
PostgreSQL-powered mailer:
Twitter: @DanielVerite

Attachment Content-Type Size
psql-crosstabview-diff-over-v16.diff text/x-patch 10.2 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Pierre-Emmanuel André 2016-04-08 10:48:16 Re: Proposal: BSD Authentication support
Previous Message Christian Ullrich 2016-04-08 10:19:08 Lower msvc build verbosity level