Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...


1. 为了存储的方便,第二种情况的存储,没有把tag的value存入路径中,即直接把tag的key存入路径中。其表现为![influxdb-test-result](https://github.com/apache/iotdb-bin-resources/blob/main/docs/UserGuide/API/IoTDB-InfluxDB/influxdb-test-result.png?raw=true)

前面累积的path都是相同的,这样最后会导致的结果是:会加快根据path过滤的查找,如:

```sql
select * from root.teststress.test2.*.*.*.*.SL.*.*.*.*.*
```

这时只有一条路径,所有速度会变快,即第二种查找的时间会比实际的快一些

5.4测试结果


第二种查找的时间平均可以达到1000多ms,第二种查找的时间在300ms附近第一种查找的时间平均可以达到1000多ms,第二种查找的时间在300ms附近

同时如果第二种查找的时候,在较靠前的路径使用*,(select * from root.teststress.test2.* where A=1 and B=1 )会导致需要查找的path过多,报错信息如下

```log
Too many paths in one query! Currently allowed max deduplicated path number is 715, this query contains 1000 deduplicated path. Please use slimit to choose what you real want or adjust max_deduplicated_path_num in iotdb-engine.properties.
​```

综上所述,建议采取**第二种第一种**方案(把tag放在path中存储)(同时需要解决上述提到的问题:Too many paths in one query)。

...