diff --git a/adminer/include/functions.inc.php b/adminer/include/functions.inc.php index 75795c73..b71c4ead 100644 --- a/adminer/include/functions.inc.php +++ b/adminer/include/functions.inc.php @@ -302,7 +302,7 @@ function where_check($val) { * @return string */ function where_link($i, $column, $value, $operator = "=") { - return "&where%5B$i%5D%5Bcol%5D=" . urlencode($column) . "&where%5B$i%5D%5Bop%5D=" . urlencode($operator) . "&where%5B$i%5D%5Bval%5D=" . urlencode($value); + return "&where%5B$i%5D%5Bcol%5D=" . urlencode($column) . "&where%5B$i%5D%5Bop%5D=" . urlencode((isset($value) ? $operator : "IS NULL")) . "&where%5B$i%5D%5Bval%5D=" . urlencode($value); } /** Set cookie valid for 1 month diff --git a/adminer/select.inc.php b/adminer/select.inc.php index d9f56214..0d814612 100644 --- a/adminer/select.inc.php +++ b/adminer/select.inc.php @@ -336,7 +336,7 @@ if (!$columns) { } } foreach ($unique_array as $k => $v) { - $link .= h(where_link($i++, $k, $v, (isset($v) ? "=" : "IS NULL"))); + $link .= h(where_link($i++, $k, $v)); } } }