@@ -50,7 +50,7 @@ IoTDB > set storage group to root.sgcc
```
IoTDB> set storage group to root.ln.wf01
error: The prefix of root.ln.wf01 has been set to the storage group.
Msg: org.apache.iotdb.exception.MetadataErrorException: org.apache.iotdb.exception.PathErrorException: The prefix of root.ln.wf01 has been set to the storage group.
```
### 查看存储组
...
...
@@ -103,11 +103,7 @@ IoTDB> show timeseries root.ln
@@ -95,12 +95,12 @@ When `*` appears in the middle of the path, it represents `*` itself, i.e., a la
* Timestamp
The timestamp is the time point at which a data arrives. IoTDB timestamps are divided into two types: LONG and DATETIME (including DATETIME-INPUT and DATETIME-DISPLAY). When a user enters a timestamp, he can use a LONG type timestamp or a DATETIME-INPUT type timestamp, where the support format of the DATETIME-INPUT type timestamp is shown in Table 2-1.
The timestamp is the time point at which a data arrives. IoTDB timestamps are divided into two types: LONG and DATETIME (including DATETIME-INPUT and DATETIME-DISPLAY). When a user enters a timestamp, he can use a LONG type timestamp or a DATETIME-INPUT type timestamp, where the support format of the DATETIME-INPUT type timestamp is shown in table:
<center>**Table 2-1 Support format of DATETIME-INPUT type timestamp**
<center>**Support format of DATETIME-INPUT type timestamp**
|format|
|:---:|
|:---|
|yyyy-MM-dd HH:mm:ss|
|yyyy/MM/dd HH:mm:ss|
|yyyy.MM.dd HH:mm:ss|
...
...
@@ -129,9 +129,9 @@ The timestamp is the time point at which a data arrives. IoTDB timestamps are di
</center>
IoTDB can support LONG types and DATETIME-DISPLAY types when displaying timestamps. The DATETIME-DISPLAY type can support user-defined time formats. The syntax of the custom time format is shown in Table 2-2.
IoTDB can support LONG types and DATETIME-DISPLAY types when displaying timestamps. The DATETIME-DISPLAY type can support user-defined time formats. The syntax of the custom time format is shown in table:
<center>**Table 2-2 The syntax of the custom time format**
@@ -31,7 +31,7 @@ IoTDB supports six data types in total:
* TEXT (String).
The time series of **FLOAT** and **DOUBLE** type can specify (MAX\_POINT\_NUMBER, see [this page](/#/Documents/latest/chap5/sec1) for more information on how to specify), which is the number of digits after the decimal point of the floating point number, if the encoding method is [RLE](/#/Documents/latest/chap2/sec3) or [TS\_2DIFF](/#/Documents/latest/chap2/sec3)(Refer to [Create Timeseries Statement](/#/Documents/latest/chap5/sec1) for more information on how to specify). If MAX\_POINT\_NUMBER is not specified, the system will use [float\_precision](/#/Documents/latest/chap2/sec3) in the configuration file "tsfile-format.properties" for configuration for the configuration method.
The time series of **FLOAT** and **DOUBLE** type can specify (MAX\_POINT\_NUMBER, see [this page](/#/Documents/latest/chap5/sec1) for more information on how to specify), which is the number of digits after the decimal point of the floating point number, if the encoding method is [RLE](/#/Documents/latest/chap2/sec3) or [TS\_2DIFF](/#/Documents/latest/chap2/sec3)(Refer to [Create Timeseries Statement](/#/Documents/latest/chap5/sec1) for more information on how to specify). If MAX\_POINT\_NUMBER is not specified, the system will use [float\_precision](/#/Documents/latest/chap4/sec2) in the configuration file "tsfile-format.properties" for configuration for the configuration method.
* For Float data value, The data range is (-Integer.MAX_VALUE, Integer.MAX_VALUE), rather than Float.MAX_VALUE, and the max_point_number is 19, it is because of the limition of function Math.round(float) in Java.
* For Double data value, The data range is (-Long.MAX_VALUE, Long.MAX_VALUE), rather than Double.MAX_VALUE, and the max_point_number is 19, it is because of the limition of function Math.round(double) in Java (Long.MAX_VALUE=9.22E18).
@@ -48,7 +48,7 @@ It is worth noting that when the path itself or the parent/child layer of the pa
```
IoTDB> set storage group to root.ln.wf01
error: The prefix of root.ln.wf01 has been set to the storage group.
Msg: org.apache.iotdb.exception.MetadataErrorException: org.apache.iotdb.exception.PathErrorException: The prefix of root.ln.wf01 has been set to the storage group.
```
### Show Storage Group
...
...
@@ -99,12 +99,7 @@ The results are shown below respectly:
@@ -43,7 +43,7 @@ IoTDB > insert into root.ln.wf02.wt02(timestamp,status) values(1,true)
IoTDB > insert into root.ln.wf02.wt02(timestamp,hardware) values(1, "v1")
```
The above example code inserts the long integer timestamp and the value "true" into the timeseries `root.ln.wf02.wt02.status` and inserts the long integer timestamp and the value "v1" into the timeseries `root.ln.wf02.wt02.hardware`. When the execution is successful, a prompt "execute successfully" will appear to indicate that the data insertion has been completed.
The above example code inserts the long integer timestamp and the value "true" into the timeseries `root.ln.wf02.wt02.status` and inserts the long integer timestamp and the value "v1" into the timeseries `root.ln.wf02.wt02.hardware`. When the execution is successful, cost time will appear to indicate that the data insertion has been completed.
> Note: In IoTDB, TEXT type data can be represented by single and double quotation marks. The insertion statement above uses double quotation marks for TEXT type data. The following example will use single quotation marks for TEXT type data.
where time > 2017-11-01T00:05:00.000 and time < 2017-11-01T00:12:00.000
slimit 1 soffset 1
select * from root.ln.wf01.wt01 where time > 2017-11-01T00:05:00.000 and time < 2017-11-01T00:12:00.000 slimit 1 soffset 1
```
which means:
...
...
@@ -394,9 +392,6 @@ The SQL statement is:
```
select max_value(*) from root.ln.wf01.wt01 group by (1d, [2017-11-01T00:00:00, 2017-11-07T23:00:00]) slimit 1 soffset 1
```
which means:
The selected device is ln group wf01 plant wt01 device; the selected timeseries is the second column under this device, i.e., the temperature.
The result is shown below:
...
...
@@ -448,9 +443,7 @@ The result is shown below:
When the parameter N/SN of LIMIT/SLIMIT exceeds the size of the result set, IoTDB will return all the results as expected. For example, the query result of the original SQL statement consists of six rows, and we select the first 100 rows through the LIMIT clause:
```
select status,temperature from root.ln.wf01.wt01
where time > 2017-11-01T00:05:00.000 and time < 2017-11-01T00:12:00.000
limit 100
select status,temperature from root.ln.wf01.wt01 where time > 2017-11-01T00:05:00.000 and time < 2017-11-01T00:12:00.000 limit 100
@@ -46,7 +46,7 @@ When the updated path does not exist, IoTDB will give the corresponding error pr
```
IoTDB> update root.ln.wf02 set wt02.sta = false where time < now()
error: do not select any existing path
Msg: do not select any existing series
```
### Data Deletion
...
...
@@ -64,7 +64,7 @@ delete from root.ln.wf02.wt02.status where time<=2017-11-01T16:26:00;
```
#### Delete Multiple Timeseries
When both the power supply status and hardware version of the ln group wf02 plant wt02 device before 2017-11-01 16:26:00 need to be deleted, the prefix path with broader meaning (see Section 3.1.6 of this manual) or the path with star can be used to delete the data. The SQL statement for this operation is:
When both the power supply status and hardware version of the ln group wf02 plant wt02 device before 2017-11-01 16:26:00 need to be deleted, [the prefix path with broader meaning or the path with star](/#/Documents/latest/chap2/sec1) can be used to delete the data. The SQL statement for this operation is:
```
delete from root.ln.wf02.wt02 where time <= 2017-11-01T16:26:00;
...
...
@@ -78,5 +78,5 @@ It should be noted that when the deleted path does not exist, IoTDB will give th
```
IoTDB> delete from root.ln.wf03.wt02.status where time < now()
error: TimeSeries does not exist and cannot be delete data
Msg: TimeSeries does not exist and its data cannot be deleted
@@ -206,7 +206,7 @@ The detail of each variables are as follows:
|Name| data\_dirs |
|:---:|:---|
|Description| The directories of data files. Multiple directories are separated by comma. See the [mult\_dir\_strategy](/#/Documents/latest/chap4/sec2) configuration item for data distribution strategy. The starting directory of the relative path is related to the operating system. It is recommended to use an absolute path. If the path does not exist, the system will automatically create it.|
|Description| The directories of data files. Multiple directories are separated by comma. See the [multi\_dir\_strategy](/#/Documents/latest/chap4/sec2) configuration item for data distribution strategy. The starting directory of the relative path is related to the operating system. It is recommended to use an absolute path. If the path does not exist, the system will automatically create it.|
|Type|String[]|
|Default| data/data |
|Effective|After restart system|
...
...
@@ -229,9 +229,9 @@ The detail of each variables are as follows:
|Default| true |
|Effective|After restart system|
* mult\_dir\_strategy
* multi\_dir\_strategy
|Name| mult\_dir\_strategy |
|Name| multi\_dir\_strategy |
|:---:|:---|
|Description| IoTDB's strategy for selecting directories for TsFile in tsfile_dir. You can use a simple class name or a full name of the class. The system provides the following three strategies: <br>1. SequenceStrategy: IoTDB selects the directory from tsfile\_dir in order, traverses all the directories in tsfile\_dir in turn, and keeps counting;<br>2. MaxDiskUsableSpaceFirstStrategy: IoTDB first selects the directory with the largest free disk space in tsfile\_dir;<br>3. MinFolderOccupiedSpaceFirstStrategy: IoTDB prefers the directory with the least space used in tsfile\_dir;<br>4. <UserDfineStrategyPackage> (user-defined policy)<br>You can complete a user-defined policy in the following ways:<br>1. Inherit the cn.edu.tsinghua.iotdb.conf.directories.strategy.DirectoryStrategy class and implement its own Strategy method;<br>2. Fill in the configuration class with the full class name of the implemented class (package name plus class name, UserDfineStrategyPackage);<br>3. Add the jar file to the project. |
|Type|String|
...
...
@@ -256,7 +256,7 @@ The detail of each variables are as follows: