PostgreSQL: Quote array values in export (bug #621)

This commit is contained in:
Jakub Vrana 2018-09-19 09:49:56 +02:00
parent 65c52735fb
commit cd3231b4af
2 changed files with 2 additions and 1 deletions

View file

@ -843,7 +843,7 @@ class Adminer {
foreach ($row as $key => $val) {
$field = $fields[$key];
$row[$key] = ($val !== null
? unconvert_field($field, preg_match(number_type(), $field["type"]) && $val != '' ? $val : q(($val === false ? 0 : $val)))
? unconvert_field($field, preg_match(number_type(), $field["type"]) && $val != '' && !preg_match('~\[~', $field["full_type"]) ? $val : q(($val === false ? 0 : $val)))
: "NULL"
);
}

View file

@ -6,6 +6,7 @@ Fix function change with set data type
Increase username maxlength to 80 (bug #623)
Make maxlength in all fields a soft limit
MySQL: Support foreign keys created with ANSI quotes (bug #620)
PostgreSQL: Quote array values in export (bug #621)
MSSQL: Pass database when connecting
ClickHouse: Connect, databases list, tables list, select, SQL command
Georgian translation