questdb/questdb

CREATE TABLE AS SELECT does not support all possible casting

Open

#6,583 创建于 2025年12月30日

在 GitHub 查看
 (1 评论) (0 反应) (0 负责人)Java (13,403 star) (972 fork)batch import
BugGood first issue

描述

To reproduce

CREATE AS SELECT has a special syntax of casting. This is a valid syntax: create table t as (select * from long_sequence(5)), cast(x as long); (note the comma before cast)

However, it does not allow all supported casting. This works fine: create table t as (select cast (x as varchar) as x from long_sequence(5)); but this does not: create table t as (select x from long_sequence(5)), cast(x as varchar); -> unsupported cast [column=x, from=LONG, to=VARCHAR]

As a user I would expect that the special casting syntax in CREATE AS SELECT would support all casting combinations allowed in regular casting expressions.

QuestDB version:

9.2.3

OS, in case of Docker specify Docker and the Host OS:

NA

File System, in case of Docker specify Host File System:

NA

Full Name:

Jaromir Hamala

Affiliation:

QuestDB

Have you followed Linux, MacOs kernel configuration steps to increase Maximum open files and Maximum virtual memory areas limit?

  • Yes, I have

Additional context

No response

贡献者指南