sosedoff / pgweb

Cross-platform client for PostgreSQL databases
https://sosedoff.github.io/pgweb
MIT License
8.63k stars 732 forks source link

Kill a running query #10

Closed julien-duponchelle closed 7 years ago

julien-duponchelle commented 10 years ago

Nice application,

I have an enhancement suggestion. You can add an option in order to kill a running query.

Have a nice day

sosedoff commented 10 years ago

This seems to be interesting, however i'm not planning on getting this implemented in the next releases.

kespindler commented 9 years ago

It'd also be useful to know how long an ongoing query has been running. A simple javascript timer on the page would suffice for this purpose.

sosedoff commented 9 years ago

@kespindler javascript timer would be irrelevant in case if you run a query on non-local servers. Results table also takes some time. So if we want to have query execution time, it has to be done via backend.

sosedoff commented 9 years ago

Stopping a running query is currently in works.

codeBearer commented 9 years ago

Is it possible to use pgweb as a service? Or what should be the proper way to deploy it?

spaquet commented 9 years ago

+1

flesler commented 8 years ago

I think this should be pretty easy to make.

You already made the Activity tab, it has which one is active and what's the pid. I imagine active queries having a "kill" button that executes this:

SELECT pg_cancel_backend(pid);

And Activity tab is refreshed. That should do no?

sosedoff commented 7 years ago

Implemented in master