Hello!

To see the file structure, click on "tree".

Note that updates take place every 10 minutes, commits may not be seen immediately.
Added dbconnect_auto subroutine to allow for db connection with supplied credentials...
authorelserj <elserj@localhost>
Wed, 25 Jan 2012 00:20:51 +0000 (00:20 +0000)
committerelserj <elserj@localhost>
Wed, 25 Jan 2012 00:20:51 +0000 (00:20 +0000)
svn path=/; revision=276

interactome_scripts/DbiFloret.pm

index b99a56bdb1da92d55b5705ad45e323784febd5a9..a4dc781e1e8469295f7e9a807b463a46a1a91576 100755 (executable)
@@ -24,6 +24,21 @@ sub dbconnect {
        
        return $dbh;
 }
+
+sub dbconnect_auto {
+               my $self =@_;
+               
+               my $username = $_[0];
+               my $password = $_[1];
+               my $database = $_[2];
+               
+               my $dbh = DBI->connect("DBI:mysql:$database;host=floret.cgrb.oregonstate.edu", $username, $password,
+               { RaiseError=> 1, AutoCommit=>1 }
+               ) or die "Failed to connect to database: $DBI::errstr";
+               
+       
+       return $dbh;
+}
        
 
 return 1;