I have an import with quite a lot of fields mapped.

When i try to add an additional mapping field I get the error "Data truncated. Data too long for column..."

Solution is to set the config column size to big.
Attaching patch in first comment.

Members fund testing for the Drupal project. Drupal Association Learn more


theduke’s picture

Priority: Normal » Major
Status: Active » Needs review
851 bytes


Also changing priority to major since this completely breaks functionality once reaching a certain config size.

theduke’s picture

Whoops, missing comma...

twistor’s picture

Status: Needs review » Needs work

hook_schema needs to be updated as well. Also, while we're at it, let's change from text to blob. Would it make more sense to split the configs into three separate columns? How many mappings do you have?

theduke’s picture

Status: Needs work » Needs review
1.79 KB

I don't think it's necessary to split into 3 columns.
MySQL longblob/longtext columns can hold 4GB of data.
That should suffice.

I'm attaching a patch that changes both config fields to blob.

It's probably not necessary to change the source config to big,
but let's make them consistent.

theduke’s picture

Are the changes ok for you twistor?

stylesuxx’s picture

As stated (and closed as duplicate) here: http://drupal.org/node/1736438 I'd like to see this changed too :-)

theduke’s picture


twistor’s picture

Status: Needs review » Patch (to be ported)
twistor’s picture

How many mappings do you have?

stylesuxx’s picture

About 320.

lyricnz’s picture

It seems db_change_field() didn't work for SQL server - #1828950: Update to alpha7 database update fails on MSSQL

MegaChriz’s picture

Issue summary: View changes
Status: Patch (to be ported) » Fixed

This was fixed a long time ago.

MegaChriz’s picture

Status: Fixed » Closed (fixed)