Uploaded image for project: 'Apache Trafodion (Retired)'
  1. Apache Trafodion (Retired)
  2. TRAFODION-2669

Error message of 8402 cause misunderstanding

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • any
    • 2.2.0
    • sql-general
    • None

    Description

      When inserting a value longer than the column data type, the error message caused misunderstanding.

      Why 21 bytes can not be inserted into 24 bytes?

      SQL>showddl test_utf8;

      CREATE TABLE TRAFODION.SEABASE.TEST_UTF8
      (
      A VARCHAR(6 CHARS) CHARACTER SET UTF8
      COLLATE DEFAULT DEFAULT NULL NOT SERIALIZED
      )
      ATTRIBUTES ALIGNED FORMAT
      ;

      — SQL operation complete.

      SQL>insert into test_utf8 values('我我我我我我');

      — 1 row(s) inserted.

      SQL>insert into test_utf8 values('我我我我我我我');

          • ERROR[8402] A string overflow occurred during the evaluation of a character expression. Conversion of Source Type:VARCHAR(REC_BYTE_V_ASCII,21 BYTES,UTF8) Source Value:我我我我我我我 to Target Type:VARCHAR(REC_BYTE_V_ASCII,24 BYTES,UTF8). [2017-06-27 15:44:45]

      Attachments

        Issue Links

          Activity

            People

              hzeller Hans Zeller
              Yuan_Liu Yuan Liu
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: