---
title: "MySql的Blob字段报错：Data truncation: Data too long for column 'CONTENT' at row 1"
author: "fucepeng"
date: "2014-11-03T09:55:59Z"
tags: []
categories: ["数据库"]
slug: "mysql-blob-data-truncation-data-too-long-for-column-content-at-row-1"
draft: false
lastmod: "2014-11-03T09:55:59Z"
id: 2151740
url: "https://fucepeng.iteye.com/blog/2151740"
---

**原因：**Mysql的blob字段最大长度为65535，而要保存的数据超过了这个长度。

 

**解决方法：**将数据库字段的类型从blob改为longblob。

 

**总结：**Mysql的其他类型也会报这个错，错误原因都是因为要保存的数据超过了此类型的最大长度限制。