1

I am trying to convert a BLOB into some text format. So I wrote a query like this, which works fine:

SELECT CAST(key_initiatives AS CHAR(1000) CHARACTER SET utf8 )  AS key_init 
FROM OBJSETTING_FOCUS_ON_CUSTOMER

If I try to create a column with a char type which does not allow more than 250 characters, when the source data allows 1000 or even 15000 characters, what will happen?

I am using MySQL GUI v9.50.

TRiG
  • 10,148
  • 7
  • 57
  • 107
vissubabu
  • 493
  • 4
  • 11
  • 25

1 Answers1

1

Have a look at this TINYTEXT, TEXT, MEDIUMTEXT, and LONGTEXT maximum storage sizes

The data type and the maximum size,

      Type | Maximum length
-----------+-------------------------------------
  TINYTEXT |           255 (2 8−1) bytes
      TEXT |        65,535 (216−1) bytes = 64 KiB
MEDIUMTEXT |    16,777,215 (224−1) bytes = 16 MiB
  LONGTEXT | 4,294,967,295 (232−1) bytes =  4 GiB
Community
  • 1
  • 1
ravikumar
  • 893
  • 1
  • 8
  • 12