Thread

  1. Re: psql: Count all table footer lines in pager setup

    Erik Wienhold <ewie@ewie.name> — 2025-10-07T09:37:34Z

    On 2025-10-07 00:45 +0200, Tom Lane wrote:
    > I wrote:
    > > Another inaccuracy that I find mildly annoying now that we've got it
    > > mostly right is that we are not accounting for the blank line that
    > > psql likes to print after the query result, so that you can still
    > > end with the first output line scrolled off your screen despite
    > > non-use of the pager.  Not sure about a non-kluge way to count that,
    > > though: it's outside the domain of print.c, and other callers might
    > > not have a similar behavior.
    > 
    > Oh wait!  That line *is* produced within print.c, so there is no
    > reason we shouldn't account for it.  I spent a little extra effort
    > on unaligned mode too, since the TAP test is checking that case.
    
    LGTM.
    
    > I still doubt that anyone's going to care a lot about the other
    > formats.
    
    Yup, I think so too.
    
    -- 
    Erik Wienhold