projects
/
eq
/
.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Unlocked (made editable) Interviewer drop down list in ppi or interview edit mode.
[eq/.git]
/
bin
/
import_ward_data
diff --git
a/bin/import_ward_data
b/bin/import_ward_data
index bd707b4da75f149659a18d4c63a6acc20481d66a..53a3c3d05aefbc4d28b5421bb2a6411da3f5e4c7 100755
(executable)
--- a/
bin/import_ward_data
+++ b/
bin/import_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 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:');
%hometeaching_data = ();
%membership_data = ();
getopts('vsn:o:');
@@
-664,7
+667,7
@@
sub check_for_changed_ids
###################################################
# 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;
@@
-726,6
+729,8
@@
if($opt_s) { $dbh->disconnect(); exit; }
&update_eq_parent_table();
&update_eq_child_table();
&update_eq_parent_table();
&update_eq_child_table();
+print "\n-> Import Successful! DONE...\n";
+
###################################################
# Disconnect from the database
$dbh->disconnect();
###################################################
# Disconnect from the database
$dbh->disconnect();
@@
-733,13
+738,3
@@
$dbh->disconnect();
######################################################################
######################################################################
-
-
-
-
-
-
-
-
-
-