Thu Sep 13 07:20:00 PDT 2007
- Previous message: [Slony1-commit] slony1-engine/doc/adminguide logshipping.sgml
- Next message: [Slony1-commit] slony1-engine/src/ducttape test_8_logship.in
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Update of /home/cvsd/slony1/slony1-engine/src/backend
In directory main.slony.info:/tmp/cvs-serv19858/src/backend
Modified Files:
slony1_funcs.sql
Log Message:
Apparently somebody decided to make "query" a reserved keyword
in the plpgsql parser.
Jan
Index: slony1_funcs.sql
===================================================================
RCS file: /home/cvsd/slony1/slony1-engine/src/backend/slony1_funcs.sql,v
retrieving revision 1.120
retrieving revision 1.121
diff -C2 -d -r1.120 -r1.121
*** slony1_funcs.sql 5 Sep 2007 21:39:57 -0000 1.120
--- slony1_funcs.sql 13 Sep 2007 14:19:58 -0000 1.121
***************
*** 5649,5653 ****
v_isorigin boolean;
v_fqname text;
! query text;
v_rows integer;
v_idxname text;
--- 5649,5653 ----
v_isorigin boolean;
v_fqname text;
! v_query text;
v_rows integer;
v_idxname text;
***************
*** 5665,5675 ****
v_fqname := ''"'' || p_nspname || ''"."'' || p_tabname || ''"'';
-- Take out a lock on the table
! query := ''lock '' || v_fqname || '';'';
! execute query;
if v_isorigin then
-- On the origin, verify that the table is empty, failing if it has any tuples
! query := ''select 1 as tuple from '' || v_fqname || '' limit 1;'';
! execute query into prec;
GET DIAGNOSTICS v_rows = ROW_COUNT;
if v_rows = 0 then
--- 5665,5675 ----
v_fqname := ''"'' || p_nspname || ''"."'' || p_tabname || ''"'';
-- Take out a lock on the table
! v_query := ''lock '' || v_fqname || '';'';
! execute v_query;
if v_isorigin then
-- On the origin, verify that the table is empty, failing if it has any tuples
! v_query := ''select 1 as tuple from '' || v_fqname || '' limit 1;'';
! execute v_query into prec;
GET DIAGNOSTICS v_rows = ROW_COUNT;
if v_rows = 0 then
***************
*** 5680,5685 ****
else
-- On other nodes, TRUNCATE the table
! query := ''truncate '' || v_fqname || '';'';
! execute query;
end if;
-- If p_idxname is NULL, then look up the PK index, and RAISE EXCEPTION if one does not exist
--- 5680,5685 ----
else
-- On other nodes, TRUNCATE the table
! v_query := ''truncate '' || v_fqname || '';'';
! execute v_query;
end if;
-- If p_idxname is NULL, then look up the PK index, and RAISE EXCEPTION if one does not exist
- Previous message: [Slony1-commit] slony1-engine/doc/adminguide logshipping.sgml
- Next message: [Slony1-commit] slony1-engine/src/ducttape test_8_logship.in
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-commit mailing list