On Thu, 5 Dec 2002, Bruce Momjian wrote:

It looks like the problem was introduced when the "SET autocommit"
and "SET search_path"  commands were added to the beginning of the script.

The attatched patch should fix the problem. It probably should be applied 
against the 7.3 and 7.4 branches.



> 
> Yes, I get the same failure. with perl 5.005_03.  Steven, can you
> comment on this?
> 
> ---------------------------------------------------------------------------
> 
> Tatsuo Ishii wrote:
> > Hi, I have been playing around with contrib/dbmirror with RC2 and
> > faced with following errors:
> > 
> >  perl DBMirror.pl slaveDatabase.conf
> > Global symbol "$setResult" requires explicit package name at DBMirror.pl line 131.
> > Global symbol "$setResult" requires explicit package name at DBMirror.pl line 132.
> > Global symbol "$setResult2" requires explicit package name at DBMirror.pl line 140.
> > Global symbol "$setResult2" requires explicit package name at DBMirror.pl line 141.
> > Execution of DBMirror.pl aborted due to compilation errors.
> > 
> > This Linux and perl 5.6.1.
> > --
> > Tatsuo Ishii
> > 
> > ---------------------------(end of broadcast)---------------------------
> > TIP 4: Don't 'kill -9' the postmaster
> > 
> 
> 

-- 
Steven Singer                                       [EMAIL PROTECTED]
Aircraft Performance Systems                Phone:  519-747-1170 ext 282
Navtech Systems Support Inc.                AFTN:   CYYZXNSX SITA: YYZNSCR
Waterloo, Ontario                           ARINC:  YKFNSCR
*** DBMirror.pl Mon Nov 25 22:31:54 2002
--- DBMirror.pl.cvs     Thu Dec  5 20:49:48 2002
***************
*** 33,39 ****
  # 
  #
  ##############################################################################
! # $Id: DBMirror.pl,v 1.4 2002/11/06 17:50:53 momjian Exp $ 
  #
  ##############################################################################
  
--- 33,39 ----
  # 
  #
  ##############################################################################
! # $Id: DBMirror.pl,v 1.3.2.1 2002/11/06 17:51:40 momjian Exp $ 
  #
  ##############################################################################
  
***************
*** 128,134 ****
      
    my $setQuery;
    $setQuery = "SET search_path = public";
!   my $setResult = $masterConn->exec($setQuery);
    if($setResult->resultStatus!=PGRES_COMMAND_OK) { 
      logErrorMessage($masterConn->errorMessage . "\n" . 
                    $setQuery);
--- 128,134 ----
      
    my $setQuery;
    $setQuery = "SET search_path = public";
!   $setResult = $masterConn->exec($setQuery);
    if($setResult->resultStatus!=PGRES_COMMAND_OK) { 
      logErrorMessage($masterConn->errorMessage . "\n" . 
                    $setQuery);
***************
*** 137,143 ****
      
    my $setQuery2;
    $setQuery2 = "SET autocommit TO 'on'";
!   my $setResult2 = $masterConn->exec($setQuery2);
    if($setResult2->resultStatus!=PGRES_COMMAND_OK) { 
      logErrorMessage($masterConn->errorMessage . "\n" . 
                    $setQuery2);
--- 137,143 ----
      
    my $setQuery2;
    $setQuery2 = "SET autocommit TO 'on'";
!   $setResult2 = $masterConn->exec($setQuery2);
    if($setResult2->resultStatus!=PGRES_COMMAND_OK) { 
      logErrorMessage($masterConn->errorMessage . "\n" . 
                    $setQuery2);
---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

Reply via email to