Fix the following error:

Drupal\Core\Entity\EntityStorageException: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'annotations_item_value' at row 2: INSERT INTO {k8s_config_map__annotations}

CommentFileSizeAuthor
#3 3094099-2.patch1.86 KBxiaohua guan

Comments

Xiaohua Guan created an issue. See original summary.

xiaohua guan’s picture

Issue summary: View changes
xiaohua guan’s picture

StatusFileSize
new1.86 KB
xiaohua guan’s picture

@yas

I changed table k8s_config_map__annotations schema like below.

BEFORE

`annotations_item_value` varchar(4096) NOT NULL,

AFTER

`annotations_item_value` longtext NOT NULL,

I think it would be better to change the type to longtext rather than to change the size to 10240, because it will be possible the data will be larger than 10240 in the future.

xiaohua guan’s picture

Status: Active » Needs review

@yas

Please review the patch file. Thanks.

yas’s picture

Status: Needs review » Reviewed & tested by the community

@xiaohua-guan

Thank you for your quick fix. I tested the patch and works well. I agree to your idea. I'll merge the patch to 8.x-2.x and close this issue as Fixed.

  • yas committed 6a3e511 on 8.x-2.x authored by Xiaohua Guan
    Issue #3094099 by Xiaohua Guan: Fix an Internal Server Error "Drupal\...
yas’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.