commandlinefu.com is the place to record those command-line gems that you return to again and again.
You can sign-in using OpenID credentials, or register a traditional username and password.
Subscribe to the feed for:
Without using a pipe.
-X ignores the user's .psqlrc configuration file
-A sets un-aligned table output mode
-t prints rows only (no headers or footers)
There are 8 alternatives - vote for the best!
In a multiple PostgreSQL server environment knowing the servers version can be important. Note that psql --version returns just the local psql apps version which may not be what you want. This command dumps the PostgreSQL servers version out to one line. You may need to add more command line options to the psql command for your connection environment.
-t, --tuples-only print rows only
If you can do better, submit your command here.
You must be signed in to comment.