-
Notifications
You must be signed in to change notification settings - Fork 34
/
Copy pathpg_squeeze--1.5--1.6.sql
47 lines (39 loc) · 1.19 KB
/
pg_squeeze--1.5--1.6.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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/* pg_squeeze--1.5--1.6.sql */
-- complain if script is sourced in psql, rather than via ALTER EXTENSION
\echo Use "ALTER EXTENSION pg_squeeze UPDATE TO '1.6'" to load this file. \quit
DROP FUNCTION process_next_task();
DROP FUNCTION squeeze_table(name, name, name, name, name[][]);
DROP FUNCTION start_worker();
CREATE FUNCTION start_worker()
RETURNS void
AS 'MODULE_PATHNAME', 'squeeze_start_worker'
LANGUAGE C;
DROP FUNCTION stop_worker();
CREATE FUNCTION stop_worker()
RETURNS void
AS 'MODULE_PATHNAME', 'squeeze_stop_worker'
LANGUAGE C;
CREATE FUNCTION squeeze_table(
tabschema name,
tabname name,
clustering_index name DEFAULT NULL,
rel_tablespace name DEFAULT NULL,
ind_tablespaces name[][] DEFAULT NULL)
RETURNS void
AS 'MODULE_PATHNAME', 'squeeze_table_new'
LANGUAGE C;
CREATE FUNCTION get_active_workers()
RETURNS TABLE (
pid int4,
tabschema name,
tabname name,
ins_initial bigint,
ins bigint,
upd bigint,
del bigint)
AS 'MODULE_PATHNAME', 'squeeze_get_active_workers'
LANGUAGE C;
ALTER TABLE log ADD COLUMN ins_initial bigint;
ALTER TABLE log ADD COLUMN ins bigint;
ALTER TABLE log ADD COLUMN upd bigint;
ALTER TABLE log ADD COLUMN del bigint;