---
name: "pgpool_adm_pcp_detach_node"
section: "3"
platform: "linux"
package: "pgpool2"
version: "4.6.1-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/pgpool_adm_pcp_detach_node"
---

# pgpool\_adm\_pcp\_detach\_node(3)

a function to detach given node ID

## NAME

pgpool\_adm\_pcp\_detach\_node - a function to detach given node ID

## SYNOPSIS

**pcp\_detach\_node returns record(integer** *node\_id***, boolean** *gracefully***, text** *host***, integer** *port***, text** *username***, text** *password***, out** *node\_detached boolean***);**

**pcp\_detach\_node returns record(integer** *node\_id***, boolean** *gracefully***, text** *pcp\_server***, out** *node\_detached boolean***);**

## DESCRIPTION

**pcp\_detach\_node** detaches a node from Pgpool-II.

## ARGUMENTS

*node\_id*

The index of backend node to detach.

*gracefully*

If true, wait for all session of pgpool-II terminates.

*pcp\_server*

The foreign server name for pcp server.

**Other arguments**

See [**pcp\_common\_options**(1)](/pcp_common_options/1.md).

## EXAMPLE

Here is an example output:

```
    test=# SELECT * FROM pcp_detach_node(node_id => 1, gracefully => 'false', host => 'localhost', port => 11001, username => 't-ishii', password => 't-ishii');
    node_detached
    ---------------
    t
    (1 row)
```
