You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/12/08 09:26:34 UTC

[GitHub] [doris] zhouhoo opened a new issue, #14936: kafka data load :the length of input is too long than schema

zhouhoo opened a new issue, #14936:
URL: https://github.com/apache/doris/issues/14936

   when I use kafka routine load to load data into doris , I got the error:
   `Reason: the length of input is too long than schema. column_name: test_id; input str: [{"test_id":"1"] schema length: 4; actual length: 14; . src line [];`
   the table in doris is as bellow:
   `CREATE TABLE `gxy_test` (
     `test_id` char(4) NOT NULL COMMENT "唯一主键",
     `create_time` datetime NULL COMMENT "创建时间",
     `name` char(50) NULL COMMENT "名字",
     `desc` varchar(150) NULL COMMENT "描述",
     `is_deleted` tinyint NULL COMMENT "是否删除",
     `update_time` datetime NULL COMMENT "更新时间"
   ) ENGINE=OLAP
   UNIQUE KEY(`test_id`, `create_time`)
   COMMENT "测试"
   PARTITION BY RANGE(`create_time`)()
   DISTRIBUTED BY HASH(`test_id`) BUCKETS 20
   PROPERTIES (
   "replication_allocation" = "tag.location.default: 1",
   "dynamic_partition.enable" = "true",
   "dynamic_partition.time_unit" = "MONTH",
   "dynamic_partition.time_zone" = "Asia/Shanghai",
   "dynamic_partition.start" = "-60",
   "dynamic_partition.end" = "2",
   "dynamic_partition.prefix" = "p",
   "dynamic_partition.replication_allocation" = "tag.location.default: 1",
   "dynamic_partition.buckets" = "12",
   "dynamic_partition.create_history_partition" = "true",
   "dynamic_partition.history_partition_num" = "12",
   "dynamic_partition.hot_partition_num" = "1",
   "dynamic_partition.reserved_history_periods" = "NULL",
   "dynamic_partition.start_day_of_month" = "1",
   "in_memory" = "false",
   "storage_format" = "V2"
   );`
   
   the data in kafka is as bellow:
   `{"test_id":"1"$$"name":"小李"$$"desc":"这是名字"$$"create_time":"2022-11-02 09:00:09"$$"is_deleted":"1"$$"update_time":"2022-11-02 09:00:09"}`
   
   so the lenght char '1' is 1 not 14 ! why doris give wrong lenght? 
   
   my doris version is 1.1.1 and kafka version is 2.13-3.3.1


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] zhouhoo closed issue #14936: kafka data load :the length of input is too long than schema

Posted by GitBox <gi...@apache.org>.
zhouhoo closed issue #14936: kafka data load :the length of input is too long than schema
URL: https://github.com/apache/doris/issues/14936


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org


[GitHub] [doris] yuanyuan8983 commented on issue #14936: kafka data load :the length of input is too long than schema

Posted by GitBox <gi...@apache.org>.
yuanyuan8983 commented on issue #14936:
URL: https://github.com/apache/doris/issues/14936#issuecomment-1343985781

   Hello, this problem is caused by the fact that the length of your data type is less than the length of the imported data. You can increase the data type of the corresponding field and then import it. You can add my WeChat account: cyllyy810222


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org