KILL CONNECTION

KILL CONNECTION — kill a connection

Syntax

KILL CONNECTION { CONNID | CONNECTION_ID } num

Description

Kill a connection by specifying a connection ID, as reported in the CONNID column in SYSTEM.CONNECTIONS.

Parameters

CONNID | CONNECTION_ID

The ID of the connection as reported in SYSTEM.CONNECTIONS.

num

Either the ID of the Node or Connection. Use SELECT * FROM SYSTEM.CONNECTIONS to find these parameters.

Example

Step 1 Find query IDs in the SYSTEM.CONNECTIONS table

SELECT sqlstring, connid FROM system.connections;

                     SQLSTRING                       CONNID
 ------------------------------------------------- -----------

 SELECT sqlstring, connid FROM system.connections; 21474836583
                                                   21474836585

Step 2 Issue KILL CONNECTION using NODEID and CONNID

KILL CONNECTION CONNID 21474836585;

# Select from system.connections again:
SELECT sqlstring, connid FROM system.connections;

                     SQLSTRING                       CONNID
 ------------------------------------------------- -----------

 SELECT sqlstring, connid FROM system.connections; 21474836583