Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit12a9322

Browse files
committed
Cancel query support from Massimo
1 parent23e1080 commit12a9322

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

‎src/backend/commands/copy.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*
77
*
88
* IDENTIFICATION
9-
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.88 1999/09/18 19:06:40 tgl Exp $
9+
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.89 1999/09/27 20:00:44 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -29,6 +29,7 @@
2929
#include"lib/stringinfo.h"
3030
#include"libpq/libpq.h"
3131
#include"miscadmin.h"
32+
#include"tcop/tcopprot.h"
3233
#include"utils/acl.h"
3334
#include"utils/builtins.h"
3435
#include"utils/syscache.h"
@@ -414,6 +415,8 @@ CopyTo(Relation rel, bool binary, bool oids, FILE *fp, char *delim)
414415

415416
while (HeapTupleIsValid(tuple=heap_getnext(scandesc,0)))
416417
{
418+
if (QueryCancel)
419+
CancelQuery();
417420

418421
if (oids&& !binary)
419422
{
@@ -686,6 +689,9 @@ CopyFrom(Relation rel, bool binary, bool oids, FILE *fp, char *delim)
686689

687690
while (!done)
688691
{
692+
if (QueryCancel)
693+
CancelQuery();
694+
689695
if (!binary)
690696
{
691697
intnewline=0;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp