1

I executed a long-running Postgres query in the psql terminal. It displayed the result, but I pressed q too soon, exiting out of the result and back to the prompt.

Is there any way for me to see the result again without rerunning the query?

user2453676
  • 470
  • 9
  • 16
Garrett
  • 4,007
  • 2
  • 41
  • 59

1 Answers1

2

You've lost that output. Though the query is likely fairly "hot" atm as it was just requested (by you).

In the future though you can use the \o [filename] syntax of psql to save the output of the command locally, such that you don't run into this issue again.

Morgan
  • 4,143
  • 27
  • 35