i2012-12-10 Miguel de Dios <miguel.dedios@artica.es>
* db/mysql.php: finish to fixed the insert in the metaconsoles. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7245 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
b6f9867ef0
commit
7df32abae4
|
@ -1,3 +1,7 @@
|
||||||
|
2012-12-10 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
|
* db/mysql.php: finish to fixed the insert in the metaconsoles.
|
||||||
|
|
||||||
2012-12-10 Sergio Martin <sergio.martin@artica.es>
|
2012-12-10 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
* pandoradb.sql
|
* pandoradb.sql
|
||||||
|
|
|
@ -287,7 +287,7 @@ function mysql_db_process_sql($sql, $rettype = "affected_rows", $dbconnection =
|
||||||
$backtrace = debug_backtrace ();
|
$backtrace = debug_backtrace ();
|
||||||
$error = sprintf ('%s (\'%s\') in <strong>%s</strong> on line %d',
|
$error = sprintf ('%s (\'%s\') in <strong>%s</strong> on line %d',
|
||||||
mysql_error (), $sql, $backtrace[0]['file'], $backtrace[0]['line']);
|
mysql_error (), $sql, $backtrace[0]['file'], $backtrace[0]['line']);
|
||||||
db_add_database_debug_trace ($sql, mysql_error ());
|
db_add_database_debug_trace ($sql, mysql_error ($dbconnection));
|
||||||
set_error_handler ('db_sql_error_handler');
|
set_error_handler ('db_sql_error_handler');
|
||||||
trigger_error ($error);
|
trigger_error ($error);
|
||||||
restore_error_handler ();
|
restore_error_handler ();
|
||||||
|
@ -295,21 +295,21 @@ function mysql_db_process_sql($sql, $rettype = "affected_rows", $dbconnection =
|
||||||
}
|
}
|
||||||
elseif ($result === true) {
|
elseif ($result === true) {
|
||||||
if ($rettype == "insert_id") {
|
if ($rettype == "insert_id") {
|
||||||
$result = mysql_insert_id ();
|
$result = mysql_insert_id ($dbconnection);
|
||||||
}
|
}
|
||||||
elseif ($rettype == "info") {
|
elseif ($rettype == "info") {
|
||||||
$result = mysql_info ();
|
$result = mysql_info ($dbconnection);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$result = mysql_affected_rows ();
|
$result = mysql_affected_rows ($dbconnection);
|
||||||
}
|
}
|
||||||
|
|
||||||
db_add_database_debug_trace ($sql, $result, mysql_affected_rows (),
|
db_add_database_debug_trace ($sql, $result, mysql_affected_rows ($dbconnection),
|
||||||
array ('time' => $time));
|
array ('time' => $time));
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
db_add_database_debug_trace ($sql, 0, mysql_affected_rows (),
|
db_add_database_debug_trace ($sql, 0, mysql_affected_rows ($dbconnection),
|
||||||
array ('time' => $time));
|
array ('time' => $time));
|
||||||
while ($row = mysql_fetch_assoc ($result)) {
|
while ($row = mysql_fetch_assoc ($result)) {
|
||||||
array_push ($retval, $row);
|
array_push ($retval, $row);
|
||||||
|
|
Loading…
Reference in New Issue