• iotdb常用命令


    #查看组
    SHOW STORAGE GROUP
    #创建TIMESERIES
    CREATE TIMESERIES root.ln.wf01.wt01.status WITH DATATYPE=BOOLEAN, ENCODING=PLAIN
    CREATE TIMESERIES root.ln.wf01.wt01.temperature WITH DATATYPE=FLOAT, ENCODING=RLE
    CREATE TIMESERIES root.ln.wf01.wt01.dag_id WITH DATATYPE=TEXT, ENCODING=PLAIN
    CREATE TIMESERIES root.ln.wf01.wt01.id WITH DATATYPE=INT32, ENCODING=PLAIN
    CREATE TIMESERIES root.ln.wf01.wt01.state WITH DATATYPE=TEXT, ENCODING=PLAIN
    #查看表
    SHOW TIMESERIES
    SHOW TIMESERIES root.ln.wf01.wt01.status
    #插入数据
    INSERT INTO root.ln.wf01.wt01(timestamp,status) values(100,true);
    INSERT INTO root.ln.wf01.wt01(timestamp,status,temperature) values(200,false,20.71)
    INSERT INTO root.ln.wf01.wt01(timestamp,id,dag_id,state) values(400,1,'test','success')
    #查询数据
    SELECT status FROM root.ln.wf01.wt01
    SELECT id,dag_id,state FROM root.ln.wf01.wt01
    
    # 插入更新 别名、标签、属性
    ALTER timeseries root.turbine.d1.s1 UPSERT ALIAS=newAlias TAGS(unit=Degree, owner=me) ATTRIBUTES(description=ha, newAttr=v1)
    # 删除表
    delete from root.ln.wf01.wt01
    # 查询最大最小时间
    select MIN_TIME(id),MAX_TIME(id) from root.ln.wf01.wt01
    #插入当前时间
    insert into root.ln.wf01.wt01(timestamp,id,dag_id,state) values(now(),1,'www','failure')
  • 相关阅读:
    web版ssh的使用
    Django高级篇三。restful的解析器,认证组件,权限组件
    Django中的缓存(内存,文件,redis)
    Python使用redis
    跨域请求
    python发送邮箱
    登录服务器失败 IP 统计和处理方法
    centos中单进程监控
    编译搭建lnmp+zabbix
    Django+Uwsgi+Nginx项目部署文档
  • 原文地址:https://www.cnblogs.com/wangbin2188/p/14694704.html
Copyright © 2020-2023  润新知