--- trunk/admin/include/update.php 2004/03/04 22:43:17 41 +++ trunk/admin/include/update.php 2004/03/04 22:43:50 42 @@ -60,14 +60,14 @@ if ($staff_id > 0) { $sql = "UPDATE staff SET password = NULL WHERE staff_id = " . $staff_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ $problem = 1; sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Purged password successfully for this staff account.

\n"); } @@ -139,13 +139,13 @@ . " WHERE coursesub_id =" . $coursesub_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Updated %s course subject.

\n", $coursesub_display); } } @@ -222,13 +222,13 @@ . "' WHERE faculty_id =" . $faculty_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Successfully updated Faculty %s

\n", $faculty_name_display); } } @@ -300,13 +300,13 @@ . "' WHERE feature_id =" . $feature_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Updated %s feature.

\n", $feature_display); } } @@ -373,14 +373,14 @@ . " WHERE infotype_id = " . $infotype_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ $err_code = 1; sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Updated affected RQS relationships (if any)
\n"); } } @@ -398,14 +398,14 @@ . " WHERE infotype_id =" . $infotype_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ $err_code = 1; sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Updated Information Type to %s.

\n", $infotype_display); } @@ -490,13 +490,13 @@ . " WHERE libunit_id =" . $libunit_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); // Call the libunit form back formLibunit($con, $libunit_id); @@ -605,13 +605,13 @@ . "' WHERE location_id =" . $location_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Updated Location to %s.

\n", $location_display); } } @@ -667,13 +667,13 @@ . "') WHERE staff_id =" . $staff_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); // Call the staff form back formStaff($con, $staff_id); @@ -760,14 +760,14 @@ // printf("sql was: %s

\n", $sql); // Edit the record - mysql_query ("LOCK TABLE resource WRITE", $con); - if (!mysql_query($sql, $con)){ + xx_query ("LOCK TABLE resource WRITE", $con); + if (!xx_query($sql, $con)){ sql_err($con); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query("UNLOCK TABLES", $con); + xx_query("UNLOCK TABLES", $con); formResource($con, $key_id, 0, 0, ''); } @@ -847,13 +847,13 @@ . "' WHERE service_id =" . $service_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); // Call the service form back formService($con, $service_id); @@ -939,13 +939,13 @@ . " = " . $key_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("%s successfully changed to %s.\n", $display, $newValue_display); } @@ -1034,14 +1034,14 @@ . "' WHERE staff_id =" . $staff_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { // Success. Call formStaff back. - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); formStaff($con, $staff_id); } } @@ -1122,13 +1122,13 @@ . "' WHERE style_id =" . $style_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); printf("Successfully updated %s style.", $style_title_display); } } @@ -1191,13 +1191,13 @@ . $sublocation_id . " WHERE subject_id = " . $subject_id; - if (!mysql_query ($sql, $con)){ + if (!xx_query ($sql, $con)){ sql_err($sql); - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); bailout(); } else { - mysql_query ("UNLOCK TABLES", $con); + xx_query ("UNLOCK TABLES", $con); formSubject($con, $subject_id); } // updated subject