【问题标题】:TDengine database join stable "invalid column name"TDengine 数据库连接稳定“列名无效”
【发布时间】:2021-08-26 06:17:35
【问题描述】:

SQL命令为:
select int_col from super, superb where super.ts = superb.ts and super.int_tag = sup erb.int_tag;
结果显示DB error: invalid operation: invalid column name
但是,我检查了我的stable的列名,没有问题:

谁能告诉这里有什么问题?我认为我的 SQL 命令中没有语法错误

【问题讨论】:

    标签: tdengine


    【解决方案1】:

    select int_col from super, superb where super.ts = superb.ts and super.int_tag = sup erb.int_tag; 中的int_col 毫无意义,因为您的两个超级表都有一个名为int_col 的列。
    您应该将您的 SQL 命令更改为:
    select super.int_col from super, superb where super.ts = superb.ts and super.int_tag = sup erb.int_tag;

    select superb.int_col from super, superb where super.ts = superb.ts and super.int_tag = sup erb.int_tag;

    【讨论】:

      猜你喜欢
      • 2021-10-06
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-12-11
      • 1970-01-01
      • 2013-03-31
      • 1970-01-01
      相关资源
      最近更新 更多