> I find myself doing this frequently with any long-running command, > but currently it's a PITA because I'd doing it at the shell level and > firing up a new psql: more work than should be necessary, and psql > sometimes gets confused when you resume it from the background in > interactive mode (stops echoing characters, though maybe this has > been fixed).
I would recommend trying out the 'screen' utility (see my other post too). And here you find a nice .screenrc too which will show you a status bar of your active session, I find it super cool (and it's well commented if you don't like it as it is): http://home.insightbb.com/~bmsims1/Scripts/Screenrc.html The man page has all commands you need, the most used by me: Ctrl-a Ctrl-c -> open a new session; Ctrl-a A -> name the session 8will show up with that name in the status bar, note that the second key is a capital A not a); Ctrl-a Ctrl-a -> switch to the last viewed session; Ctrl-a <n> -> switch to the <n>th session, where <n> is a digit 0-9 I usually leave the screen sessions running end detach only the terminal, and then I can connect again to the already set up sessions using "screen -R". It's a real time saver. It has many more facilities, and creating a new psql session is just Ctrl-a Ctrl-c and then type in psql... and you're good to go... I don't think you can beat that by a large margin with psql-intern commands (you still need to type in something extra), and you do have added benefits of clearly separated workflows and a nice overview of it. Cheers, Csaba. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers