Don't use LIKE for numbers (http://forum.zdrojak.root.cz/index.php?topic=567)
This commit is contained in:
parent
1e70b74f4c
commit
af3b762067
|
@ -337,7 +337,7 @@ function where($where) {
|
||||||
$return = array();
|
$return = array();
|
||||||
foreach ((array) $where["where"] as $key => $val) {
|
foreach ((array) $where["where"] as $key => $val) {
|
||||||
$return[] = idf_escape(bracket_escape($key, 1)) // 1 - back
|
$return[] = idf_escape(bracket_escape($key, 1)) // 1 - back
|
||||||
. (ereg('\\.', $val) || $jush == "mssql" ? " LIKE " . exact_value(addcslashes($val, "%_\\")) : " = " . exact_value($val)) // LIKE because of floats, but slow with ints, in MS SQL because of text
|
. ((ereg('\\.', $val) || $jush == "mssql") && $jush != "pgsql" ? " LIKE " . exact_value(addcslashes($val, "%_\\")) : " = " . exact_value($val)) // LIKE because of floats, but slow with ints, in MS SQL because of text
|
||||||
; //! enum and set
|
; //! enum and set
|
||||||
}
|
}
|
||||||
foreach ((array) $where["null"] as $key) {
|
foreach ((array) $where["null"] as $key) {
|
||||||
|
|
|
@ -9,6 +9,7 @@ Esc to cancel AJAX request
|
||||||
Ability to disable export (customization)
|
Ability to disable export (customization)
|
||||||
MySQL: set autocommit after connect
|
MySQL: set autocommit after connect
|
||||||
PostgreSQL: fix alter foreign key
|
PostgreSQL: fix alter foreign key
|
||||||
|
PostgreSQL: don't use LIKE for numbers
|
||||||
PostgreSQL over PDO: connect if the eponymous database does not exist (bug #3391619)
|
PostgreSQL over PDO: connect if the eponymous database does not exist (bug #3391619)
|
||||||
Boolean search (Editor)
|
Boolean search (Editor)
|
||||||
Persian translation
|
Persian translation
|
||||||
|
|
Loading…
Reference in a new issue