From 97f4d625710adda0d4cf6295336c3cae1a393477 Mon Sep 17 00:00:00 2001 From: Dan Gebhardt <gebhardt@flux.utah.edu> Date: Mon, 8 Jan 2007 17:59:15 +0000 Subject: [PATCH] a few bug fixes. --- pelab/libwanetmondb.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pelab/libwanetmondb.pm b/pelab/libwanetmondb.pm index 8937e89580..ae10896d54 100644 --- a/pelab/libwanetmondb.pm +++ b/pelab/libwanetmondb.pm @@ -72,9 +72,8 @@ sub getRows($) if( !defined $t0 || !defined $t1 ){ #use Ops $useOps = 1; -# $t0 = time() - ($OpsDataDuration-1)*60*60; -# $t1 = time(); } +# print "t0=$t0\nt1=$t1\n$query\n"; #Determine whether to go to DPos or Ops databases if( defined $t0 && @@ -91,7 +90,7 @@ sub getRows($) if( $useOps ){ # print "USING OPS\n"; - TBDBConnect($OPSDBNAME, $DBUSER, $dbpwd) == 0 + TBDBConnect($OPSDBNAME, $DBUSER, $dbpwd,"") == 0 or die("Could not connect to ops/pelab database!\n"); my $query_result = DBQueryFatal($query); if (! $query_result->numrows) { @@ -102,6 +101,7 @@ sub getRows($) push @rows, $hrow; } }else{ +# print "USING DP: $query\n"; TBDBConnect($DPDBNAME, $DBUSER, $dbpwd,$DPDBHOST) == 0 or die("Could not connect to nfs/pelab database!\n"); my $query_result = DBQueryFatal($query); @@ -112,6 +112,7 @@ sub getRows($) while( my $hrow = $query_result->fetchrow_hashref() ){ push @rows, $hrow; } +# print "finished DP\n"; } return @rows; -- GitLab