Browse Source

fix: sanitize before comparing column_names

Signed-off-by: mertmit <mertmit99@gmail.com>
pull/6648/head
mertmit 1 year ago
parent
commit
5a9119fdc8
  1. 3
      packages/nocodb/src/modules/jobs/jobs/export-import/import.service.ts

3
packages/nocodb/src/modules/jobs/jobs/export-import/import.service.ts

@ -34,6 +34,7 @@ import { ViewsService } from '~/services/views.service';
import NcPluginMgrv2 from '~/helpers/NcPluginMgrv2';
import { BulkDataAliasService } from '~/services/bulk-data-alias.service';
import NcConnectionMgrv2 from '~/utils/common/NcConnectionMgrv2';
import { sanitizeColumnName } from '~/helpers';
@Injectable()
export class ImportService {
@ -149,7 +150,7 @@ export class ImportService {
// map column id's with new created column id's
for (const col of table.columns) {
const colRef = modelData.columns.find(
(a) => a.column_name === col.column_name,
(a) => sanitizeColumnName(a.column_name) === col.column_name,
);
idMap.set(colRef.id, col.id);

Loading…
Cancel
Save