Fri Feb 12 09:16:07 PST 2010
- Previous message: [Slony1-commit] slony1-engine/src/backend slony1_funcs.sql
- Next message: [Slony1-commit] slony1-engine/src/backend slony1_funcs.c
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Update of /home/cvsd/slony1/slony1-engine/src/backend In directory main.slony.info:/tmp/cvs-serv15322 Modified Files: slony1_funcs.sql Log Message: Port fixes in 2.0 to HEAD... 1. Inapropos number of parms for insert to confirmations table 2. Change UPDATEs that break as of 9.0 Index: slony1_funcs.sql =================================================================== RCS file: /home/cvsd/slony1/slony1-engine/src/backend/slony1_funcs.sql,v retrieving revision 1.157 retrieving revision 1.158 diff -C 2 -d -r1.157 -r1.158 *** slony1_funcs.sql 26 Nov 2009 18:09:17 -0000 1.157 --- slony1_funcs.sql 12 Feb 2010 17:16:05 -0000 1.158 *************** *** 2424,2429 **** (ssy_setid, ssy_origin, ssy_seqno, ssy_snapshot, ssy_action_list) ! values (p_set_id, p_new_origin, '0', ! '0', '0', '1:1:', NULL); end if; end if; --- 2424,2429 ---- (ssy_setid, ssy_origin, ssy_seqno, ssy_snapshot, ssy_action_list) ! values (p_set_id, p_new_origin, ! '0', '1:1:', NULL); end if; end if; *************** *** 5117,5138 **** end loop; ! update @NAMESPACE at .sl_table set ! tab_reloid = PGC.oid ! from pg_catalog.pg_class PGC, pg_catalog.pg_namespace PGN ! where @NAMESPACE at .slon_quote_brute(@NAMESPACE at .sl_table.tab_relname) = @NAMESPACE at .slon_quote_brute(PGC.relname) ! and PGC.relnamespace = PGN.oid ! and @NAMESPACE at .slon_quote_brute(PGN.nspname) = @NAMESPACE at .slon_quote_brute(@NAMESPACE at .sl_table.tab_nspname); for prec in select seq_id from @NAMESPACE at .sl_sequence loop ! update @NAMESPACE at .sl_sequence set seq_reloid = (select oid from pg_class pc where relkind <> 'S' and not exists (select 1 from @NAMESPACE at .sl_sequence t2 where t2.tab_reloid = pc.oid) limit 1) where tab_id = prec.seq_id; end loop; ! update @NAMESPACE at .sl_sequence set ! seq_reloid = PGC.oid ! from pg_catalog.pg_class PGC, pg_catalog.pg_namespace PGN ! where @NAMESPACE at .slon_quote_brute(@NAMESPACE at .sl_sequence.seq_relname) = @NAMESPACE at .slon_quote_brute(PGC.relname) and PGC.relnamespace = PGN.oid ! and @NAMESPACE at .slon_quote_brute(PGN.nspname) = @NAMESPACE at .slon_quote_brute(@NAMESPACE at .sl_sequence.seq_nspname); return 1; --- 5117,5144 ---- end loop; ! for prec in select tab_id, tab_relname, tab_nspname from @NAMESPACE at .sl_table loop ! update @NAMESPACE at .sl_table set ! tab_reloid = (select PGC.oid ! from pg_catalog.pg_class PGC, pg_catalog.pg_namespace PGN ! where @NAMESPACE at .slon_quote_brute(PGC.relname) = @NAMESPACE at .slon_quote_brute(prec.tab_relname) ! and PGC.relnamespace = PGN.oid ! and @NAMESPACE at .slon_quote_brute(PGN.nspname) = @NAMESPACE at .slon_quote_brute(prec.tab_nspname)) ! where tab_id = prec.tab_id; ! end loop; for prec in select seq_id from @NAMESPACE at .sl_sequence loop ! update @NAMESPACE at .sl_sequence set seq_reloid = (select oid from pg_class pc where relkind <> 'S' and not exists (select 1 from @NAMESPACE at .sl_sequence t2 where t2.seq_reloid = pc.oid) limit 1) where tab_id = prec.seq_id; end loop; ! for prec in select seq_id, seq_relname, seq_nspname from @NAMESPACE at .sl_sequence loop ! update @NAMESPACE at .sl_sequence set ! seq_reloid = (select PGC.oid ! from pg_catalog.pg_class PGC, pg_catalog.pg_namespace PGN ! where @NAMESPACE at .slon_quote_brute(PGC.relname) = @NAMESPACE at .slon_quote_brute(prec.seq_relname) and PGC.relnamespace = PGN.oid ! and @NAMESPACE at .slon_quote_brute(PGN.nspname) = @NAMESPACE at .slon_quote_brute(prec.seq_nspname)) ! where seq_id = prec.seq_id; ! end loop; return 1;
- Previous message: [Slony1-commit] slony1-engine/src/backend slony1_funcs.sql
- Next message: [Slony1-commit] slony1-engine/src/backend slony1_funcs.c
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-commit mailing list