1

I have model that have help_ru column that is set as text datatype.

Problem: I tried to update help_ru column from my ActiveAdmin panel, but received error message Mysql2::Error: Data too long for column 'help_ru' .

I tried to add text that has 170 000 characters with spaces. It takes aprox. 40kb when saved in text document.

I am using TinyMCE so the text includes styling information. Please,see small example of it:

<p style=\"margin-bottom: 0.14in; line-height: 115%;\">Sludinājuma izvieto&scaron;ana</p>\r\n<p style=\"margin-bottom: 0.14in; line-height: 115%;\">Bezmaksas sludinājumu apraksts:</p>\r\n<p style=\"margin-bottom: 0.14in; line-height: 115%;\">1. Lietotājam ir tiesības ievietot vienu bezmaksas sludinājumu Individualki.eu sadaļā.</p>\r\n<p style=\"margin-bottom: 0.14in; line-height: 115%;\">2. Lietotājs var ievietot vienu bezmaksas sludinājumu vienu reizi 14 (četrpadsmit) dienās. Pēc 14 (četrpadsmit) dienām sludinājums tiks automātiski dzēsts.</p>\r\n<p style=\"margin-bottom: 0.14in; line-height: 115%;\">Maksas sludinājumi :</p>\r\n<p style=\"margin-bottom: 0.14in; line-height: 115%;\">3. Maksas sludinājumus var: pievienot,

I double checked help_ru column's datatype and it is text not string (like in similair questions that I found in StackOverflow.).

I am using Mysql as database.

Why this problem persists if I don't have special restrictions and text datatype is very large?

Thanks

Edgars
  • 913
  • 1
  • 19
  • 53

0 Answers0