1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-09 08:06:59 +02:00

PostgreSQL: Do not cast number searches to text

This commit is contained in:
Jakub Vrana
2018-03-13 14:09:53 +01:00
parent 6ba77b7899
commit 89c66ccabe
3 changed files with 4 additions and 4 deletions

View File

@@ -216,7 +216,7 @@ if (isset($_GET["pgsql"])) {
function convertSearch($idf, $val, $field) {
return (preg_match('~char|text'
. (!preg_match('~LIKE~', $val["op"]) ? '|date|time(stamp)?' . (is_numeric($val["val"]) ? '|' . number_type() : '') : '')
. (!preg_match('~LIKE~', $val["op"]) ? '|date|time(stamp)?|' . number_type() : '')
. '~', $field["type"])
? $idf
: "CAST($idf AS text)"