2013-05-03 83 views
1

我建立了一個刮板,它似乎不像我的描述長度。我將列更改爲varchar(500),但沒有骰子。我想我需要轉換爲文本,但我不知道如何。這對我來說有意義嗎?謝謝!mysql- Mysql2 ::錯誤:數據太長,無法在列1'列'描述

錯誤 -

Mysql2::Error: Data too long for column 'description' at row 1: INSERT INTO sammiches (country , created_at , description , image , name , updated_at) VALUES ('Italy', '2013-05-03 01:10:08', 'In Italy, panino is the word for a sandwich made from bread other than sliced bread, in which case Italians call it a tramezzino or porco. Examples of bread types used are ciabatta, rosetta and baguette. The bread is cut horizontally and filled with deli ingredients such as salami, ham, cheese, mortadella, or other food, and sometimes served warm after having been pressed by a warming grill. In the United States, United Kingdom and Canada, the term panini has been adopted to refer to a pressed and toasted sandwich; there is widespread availability and use of sandwich presses, often known as \"panini presses\" or \"toasted sandwich makers.\"', '/wiki/File:Italian_Sandwich.jpeg', 'Panini', '2013-05-03 01:10:08') (ActiveRecord::StatementInvalid)

回答

4

你的長度是現在約650個字符。嘗試增加更多。

+0

我改成了文字,它似乎工作,遺憾的過早的問題。 – DynastySS 2013-05-03 01:18:01