Index: pending.c =================================================================== RCS file: /projects/cvsroot/pgsql-server/contrib/dbmirror/pending.c,v retrieving revision 1.16 diff -u -w -r1.16 pending.c --- pending.c 17 Feb 2004 03:34:35 -0000 1.16 +++ pending.c 18 Apr 2004 15:31:14 -0000 @@ -701,7 +701,7 @@ debug_msg("dbmirror:nextval Set resTuple"); - nextSequenceValue =*(DatumGetPointer(SPI_getbinval(resTuple, + nextSequenceValue =* (unsigned int *)(DatumGetPointer(SPI_getbinval(resTuple, SPI_tuptable->tupdesc, 1,&isNull))); Index: DBMirror.pl =================================================================== RCS file: /projects/cvsroot/pgsql-server/contrib/dbmirror/DBMirror.pl,v retrieving revision 1.8 diff -u -w -r1.8 DBMirror.pl --- DBMirror.pl 17 Feb 2004 03:34:35 -0000 1.8 +++ DBMirror.pl 18 Apr 2004 15:31:14 -0000 @@ -660,7 +660,7 @@ my $query; my $sequenceValue = $pendingResult->getvalue($currentTuple,4); - $query = sprintf("select setval(%s,%s)",$sequenceName,$sequenceValue); + $query = sprintf("select setval('%s',%s)",$sequenceName,$sequenceValue); sendQueryToSlaves($transId,$query); return $currentTuple; @@ -960,7 +960,7 @@ my $nowisdst; ($nowsec,$nowmin,$nowhour,$nowmday,$nowmon,$nowyear,$nowwday,$nowyday,$nowisdst) = localtime; - my $fileName=sprintf(">%s/%s_%d-%d-%d_%d:%d:%dXID%d.sql", $::slaveInfo->{'TransactionFileDirectory'}, + my $fileName=sprintf(">%s/%s_%02d-%02d-%02d_%02d:%02d:%dXID%d.sql", $::slaveInfo->{'TransactionFileDirectory'}, $::slaveInfo->{"MirrorHostId"},($nowyear+1900),($nowmon+1),$nowmday,$nowhour,$nowmin, $nowsec,$XID);