@@ -19,7 +19,7 @@ my %Stables = ();
19
19
20
20
sub PrepareSnapshot
21
21
{
22
- my ($conn ,$outf ,$server , $onlytables ) =@_ ;# (@_[0], @_[1], @_[2]);
22
+ my ($conn ,$outf ,$server ) =@_ ;# (@_[0], @_[1], @_[2]);
23
23
24
24
my $result =$conn -> exec (" BEGIN" );
25
25
if ($result -> resultStatusne PGRES_COMMAND_OK)
@@ -52,10 +52,6 @@ sub PrepareSnapshot
52
52
while (@row =$result -> fetchrow)
53
53
{
54
54
# printf "$row[0], $row[1], $row[2]\n";
55
- if (ref ($onlytables )eq ' HASH' ) {
56
- next unless (exists $onlytables -> {$row [1]});
57
- $onlytables -> {$row [1]} =$row [0]unless ($onlytables -> {$row [1]});
58
- }
59
55
push @{$Mtables {$row [0]}},$row [1],$row [2];
60
56
}
61
57
@@ -236,7 +232,7 @@ sub GetSYNCID
236
232
237
233
sub CleanLog
238
234
{
239
- my ($conn ,$howold , $onlytables ) =@_ ;# (@_[0], @_[1]);
235
+ my ($conn ,$howold ) =@_ ;# (@_[0], @_[1]);
240
236
241
237
my $result =$conn -> exec (" BEGIN" );
242
238
if ($result -> resultStatusne PGRES_COMMAND_OK)
@@ -278,11 +274,6 @@ sub CleanLog
278
274
my $alist =join (' ,' ,keys %active );
279
275
my $sinfo =" logid <$maxid " ;
280
276
$sinfo .=" and logid not in ($alist )" if $alist ne ' ' ;
281
- # if (ref($onlytables) eq 'HASH') {
282
- # foreach my $onlytable (keys %{$onlytables}) {
283
- # $sinfo
284
- # }
285
- # }
286
277
287
278
$sql =" delete from _RSERV_LOG_ where" .
288
279
" logtime < now() - '$howold second'::interval and$sinfo " ;
@@ -311,7 +302,7 @@ sub CleanLog
311
302
312
303
sub ApplySnapshot
313
304
{
314
- my ($conn ,$inpf , $onlytables ) =@_ ;# (@_[0], @_[1]);
305
+ my ($conn ,$inpf ) =@_ ;# (@_[0], @_[1]);
315
306
316
307
my $result =$conn -> exec (" BEGIN" );
317
308
if ($result -> resultStatusne PGRES_COMMAND_OK)
@@ -345,10 +336,6 @@ sub ApplySnapshot
345
336
while (@row =$result -> fetchrow)
346
337
{
347
338
# printf "%s%s\n", $row[1], $row[0];
348
- if (ref ($onlytables )eq ' HASH' ) {
349
- next unless (exists $onlytables -> {$row [1]});
350
- $onlytables -> {$row [1]} =$row [0]unless ($onlytables -> {$row [1]});
351
- }
352
339
push @{$Stables {$row [1]}},$row [0],$row [2],$row [3];
353
340
}
354
341