| От | Oliver Jowett |
|---|---|
| Тема | Re: Statement.cancel() doesn't seem to work |
| Дата | |
| Msg-id | 4BBACC12.9050204@opencloud.com обсуждение исходный текст |
| Ответ на | Statement.cancel() doesn't seem to work (JN <jim.newsham@gmail.com>) |
| Список | pgsql-jdbc |
JN wrote:
> Hi, I'm trying to cancel a long-running statement (takes about 400
> seconds) by calling PreparedStatement.cancel() from another thread,
> but it's not working. Specifically, the call to
> PreparedStatement.cancel() completes normally, but the executing
> statement seems to complete normally (i.e., it still takes the same
> amount of time to complete, and it does not throw any exception). The
> sql being executed is a delete ("delete from qos_data where
> report_time < ?"). Is PreparedStatement.cancel() not implemented?
It is implemented, but it just requests that the backend cancels any
query in progress - there are no guarantees that it will be effective.
Does the query get canceled if you manually send a SIGINT to the
relevant backend?
-O
В списке pgsql-jdbc по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера