Skip to content

Is there an "Expanded" view, like in psql? #1313

Description

@megamichelle

I'd love a way to pretty-print files in an "expanded" format like what psql has. That is, with the column names on the left and their values on the right, with one column displayed per row of the terminal.

Like:

-[ RECORD 1 ]-------------------------------------------------
Name        | hstore
Version     | 1.0
Schema      | jasdeep
Description | data type for storing sets of (key, value) pairs
-[ RECORD 2 ]-------------------------------------------------
Name        | plpgsql
Version     | 1.0
Schema      | pg_catalog
Description | PL/pgSQL procedural language

(example from this random blog post)

It's not useful for processing data, but it can be very useful for me as a human when I'm exploring the dataset. I would expect a pretty-print command like this would always be the last command in a pipeline.

I don't know if it would be best as its own command, like "csvprettyprint" or if it'd be better as an option to csvlook, like --expanded.

But maybe such a thing does exist and I just missed it?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions