mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-29 16:55:05 +02:00
Error fixes related with the improved oracle compatibility
This commit is contained in:
parent
0b7b32f526
commit
4008b12add
@ -253,6 +253,9 @@ switch ($config["dbtype"]) {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "oracle":
|
case "oracle":
|
||||||
|
if (!isset($config['quote_string'])) {
|
||||||
|
$config['db_quote_string'] = "'";
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
//======================================================================
|
//======================================================================
|
||||||
|
@ -453,7 +453,9 @@ function oracle_encapsule_fields_with_same_name_to_instructions($field) {
|
|||||||
|
|
||||||
if (is_string($return)) {
|
if (is_string($return)) {
|
||||||
if ($return[0] !== '"') {
|
if ($return[0] !== '"') {
|
||||||
$return = '"' . $return . '"';
|
// The columns declared without quotes are converted to uppercase in oracle.
|
||||||
|
// A column named asd is equal to asd, ASD or "ASD", but no to "asd".
|
||||||
|
$return = '"' . strtoupper($return) . '"';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2213,7 +2213,7 @@ function get_news($arguments) {
|
|||||||
case "oracle":
|
case "oracle":
|
||||||
$sql = sprintf("SELECT subject,timestamp,text,author
|
$sql = sprintf("SELECT subject,timestamp,text,author
|
||||||
FROM tnews
|
FROM tnews
|
||||||
WHERE rownum <= %limit AND id_group IN (%s) AND
|
WHERE rownum <= %s AND id_group IN (%s) AND
|
||||||
modal = %s AND
|
modal = %s AND
|
||||||
(expire = 0 OR (expire = 1 AND expire_timestamp > '%s'))
|
(expire = 0 OR (expire = 1 AND expire_timestamp > '%s'))
|
||||||
ORDER BY timestamp DESC", $limit, $id_group, $modal, $current_datetime);
|
ORDER BY timestamp DESC", $limit, $id_group, $modal, $current_datetime);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user