【问题标题】:DolphinDB data type conversion issueDolphinDB 数据类型转换问题
【发布时间】:2019-10-23 10:50:26
【问题描述】:

我遇到了以下脚本的问题:

id = id$symbol

其中 id 是一个字符串列。我收到以下错误消息:

Please specify correct data type e.g. a$int (convert variable 'a' to integer type)

这很奇怪,因为我之前多次运行过这条线并且它通过了,而且我最近没有更新 DolphinDB 数据库。有谁知道这里发生了什么?

【问题讨论】:

    标签: types dolphindb


    【解决方案1】:

    我认为您可能在此脚本之前的某处定义了变量“符号”。

    我可以使用以下脚本复制您的问题:

    >id=`AA`BB`CC
    >symbol=0;
    >id$symbol;
    Please specify correct data type e.g. a$int (convert variable 'a' to integer type)
    

    因此,只需检查您的代码并避免使用指示数据类型的词语作为变量名。

    【讨论】:

      猜你喜欢
      • 2020-09-25
      • 2015-11-30
      • 1970-01-01
      • 1970-01-01
      • 2020-02-26
      • 2016-05-23
      • 1970-01-01
      • 2023-03-13
      • 2011-11-17
      相关资源
      最近更新 更多