Reputation: 2389
I have a table that should be occupying much less space on psql command line, for some reason the format is being displayed very weirdly. Please have a look at this picture, it describes the problem better than any words I may write here.
As you may see some columns names are overlapping and the table is just ugly. If I expand the display you can see how the table is structured .
Upvotes: 0
Views: 805
Reputation: 247225
psql
does not add extra spaces to the output.
The problem must be that you have lots of training spaces at least in some of the data. psql
will align the output with the widest column in the result set.
One possibility how that can happen is if you define columns with a type like char(100)
, which will pad the value with spaces. It is a good idea to avoid the char
data type.
Upvotes: 2