- Timestamp:
- 02/07/05 12:00:47 (20 years ago)
- Location:
- branches/stable/cgi-bin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/cgi-bin/CustIDCK.pm
r151 r156 36 36 my $dbh; 37 37 eval { 38 local $SIG{ALRM} = sub { die "failed connection to billing!!" };38 local $SIG{ALRM} = sub { die "failed connection to newbilling!!" }; 39 39 alarm 3; # 3-second timeout. This may be too aggressive. 40 40 41 41 eval { 42 $dbh = DBI->connect ("DBI:Pg:host= billing;dbname=custids", "cidcheck", "c1dch4ck");43 die "failed connection to billing!!" if !$dbh;42 $dbh = DBI->connect ("DBI:Pg:host=newbilling;dbname=custids", "cidcheck", "c1dch4ck"); 43 die "failed connection to newbilling!!" if !$dbh; 44 44 # Not certain if this is needed here. It doesn't seem to be. 45 45 # $dbh->ping; # Gotta do this to "force" a "failure". NRGH. … … 49 49 }; 50 50 alarm 0; # avoid race conditions. May not be needed here. (Hah!) 51 if ($@ && $@ !~ /failed connection to billing!!/) {51 if ($@ && $@ !~ /failed connection to newbilling!!/) { 52 52 $CustIDCK::Error = 1; 53 $CustIDCK::ErrMsg = "Failed connection to billing DB host! Unable to verify CustIDs.";53 $CustIDCK::ErrMsg = "Failed connection to newbilling DB host! Unable to verify CustIDs."; 54 54 return 0; 55 55 } -
branches/stable/cgi-bin/checkcusts.pl
r128 r156 26 26 27 27 ($dbh,$errstr) = connectDB("ipdb", "ipdb", "ipdbpwd"); 28 $IDH = DBI->connect ("DBI:Pg:host= billing;dbname=custids", "cidcheck", "c1dch4ck");28 $IDH = DBI->connect ("DBI:Pg:host=newbilling;dbname=custids", "cidcheck", "c1dch4ck"); 29 29 $sth = $dbh->prepare("select cidr,custid from searchme where not (custid='6750400') ". 30 30 "and not (custid='STAFF') order by cidr");
Note:
See TracChangeset
for help on using the changeset viewer.