-
Notifications
You must be signed in to change notification settings - Fork 26
/
Copy pathinit.sql
28 lines (25 loc) · 851 Bytes
/
init.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
-- complain if script is sourced in psql, rather than via CREATE EXTENSION
\echo Use "CREATE EXTENSION pg_query_state" to load this file. \quit
CREATE FUNCTION pg_query_state(pid integer
, verbose boolean = FALSE
, costs boolean = FALSE
, timing boolean = FALSE
, buffers boolean = FALSE
, triggers boolean = FALSE
, format text = 'text')
RETURNS TABLE (pid integer
, frame_number integer
, query_text text
, plan text
, leader_pid integer)
AS 'MODULE_PATHNAME'
LANGUAGE C STRICT VOLATILE;
CREATE FUNCTION pg_progress_bar(pid integer)
RETURNS FLOAT
AS 'MODULE_PATHNAME'
LANGUAGE C STRICT VOLATILE;
CREATE FUNCTION pg_progress_bar_visual(pid integer
, delay integer = 1)
RETURNS FLOAT
AS 'MODULE_PATHNAME', 'pg_progress_bar'
LANGUAGE C STRICT VOLATILE;