mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 08:44:10 +02:00
Merge branch 'bugfix/postgres-wrong-default-timestamps-7919'
fixes #7919
This commit is contained in:
commit
0c35607e37
@ -323,6 +323,11 @@ abstract class IdoQuery extends DbQuery
|
|||||||
foreach ($columns as $key => & $value) {
|
foreach ($columns as $key => & $value) {
|
||||||
$value = preg_replace('/ COLLATE .+$/', '', $value);
|
$value = preg_replace('/ COLLATE .+$/', '', $value);
|
||||||
$value = preg_replace('/inet_aton\(([[:word:].]+)\)/i', '$1::inet - \'0.0.0.0\'', $value);
|
$value = preg_replace('/inet_aton\(([[:word:].]+)\)/i', '$1::inet - \'0.0.0.0\'', $value);
|
||||||
|
$value = preg_replace(
|
||||||
|
'/UNIX_TIMESTAMP(\((?>[^()]|(?-1))*\))/i',
|
||||||
|
'CASE WHEN ($1 < \'1970-01-03 00:00:00+00\'::timestamp with time zone) THEN 0 ELSE UNIX_TIMESTAMP($1) END',
|
||||||
|
$value
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user