projects
/
eq
/
.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Made DBI connect changes suggested by Brett Williams.
[eq/.git]
/
bin
/
parse_ward_data
diff --git
a/bin/parse_ward_data
b/bin/parse_ward_data
index 82a173038d774daa48abb8a312988a2a73c5bd77..7a3c07249ef4b5edafa6a21d19f7114a1f2fc153 100755
(executable)
--- a/
bin/parse_ward_data
+++ b/
bin/parse_ward_data
@@
-2,13
+2,16
@@
use DBI;
use Getopt::Std;
use DBI;
use Getopt::Std;
+
###################################################
# GLOBALS
$dbname = "phpgroupware";
###################################################
# GLOBALS
$dbname = "phpgroupware";
-$dbhost = "192.168.0.2";
+$dbhost = "192.168.0.2";
# This can be an IP address or a name
$dbport = 3306;
$dbport = 3306;
-$dbuser = "phpgroupware";
-$dbpass = "phpgroupware";
+$dbuser = "phpgroupware"; # This may require an additional '\@localhost'
+$dbpass = "phpgroupware";
+###################################################
+
%hometeaching_data = ();
%membership_data = ();
getopts('vsn:o:b');
%hometeaching_data = ();
%membership_data = ();
getopts('vsn:o:b');
@@
-91,7
+94,7
@@
sub print_birthdays
###################################################
# Open a connection to the database
###################################################
# Open a connection to the database
-$dbh=DBI->connect("dbi:mysql:dbname=$dbname
;host=$dbhost
port=$dbport",$dbuser,$dbpass,{
+$dbh=DBI->connect("dbi:mysql:dbname=$dbname
:host=$dbhost:
port=$dbport",$dbuser,$dbpass,{
AutoCommit=>0,
PrintError=>0}) or print "Connect Failure:".$DBI::errstr."\n" and exit 2;
AutoCommit=>0,
PrintError=>0}) or print "Connect Failure:".$DBI::errstr."\n" and exit 2;