Alexandre Alapetite 4 years ago
parent
commit
354531bfa6
1 changed files with 6 additions and 4 deletions
  1. +6
    -4
      include/dbstructure.php

+ 6
- 4
include/dbstructure.php View File

@ -399,11 +399,13 @@ function update_structure($verbose, $action, $tables=null, $definition=null) {
}
$field_list = '';
foreach ($structure['fields'] AS $fieldname => $parameters) {
$field_list .= 'ANY_VALUE(`' . $fieldname . '`),';
if ($is_unique && $ignore == '') {
foreach ($structure['fields'] AS $fieldname => $parameters) {
$field_list .= 'ANY_VALUE(`' . $fieldname . '`),';
}
$field_list = rtrim($field_list, ',');
}
$field_list = rtrim($field_list, ',');
if ($verbose) {
// Ensure index conversion to unique removes duplicates
if ($is_unique) {


Loading…
Cancel
Save