Skip to content

why presto query mysql data,the field will be transformed into char(0) #20681

Open
@hhhhhxm

Description

@hhhhhxm

i have a mysql table ,create table sql like this:
CREATE TABLE test(idbigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',content json DEFAULT NULL COMMENT '内容', ) COMMENT='测试表';

but when i query in presto with this sql ,
select typeof(content) from test
the 'content' field wil be transformed into char(0)

because the 'content' field be transformed into char(0) so i cant use this field cast(json_extract(content,'$.id') as decimal)

my presto version is 0.282

please help me

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    📋 Prioritized Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions