This is an automated email from the ASF dual-hosted git repository. qiaojialin pushed a commit to branch f_readme in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git
commit c3ad30a26085215d4f8e1dd37f9c96f8baee8d2d Author: qiaojialin <[email protected]> AuthorDate: Wed Aug 28 11:29:02 2019 +0800 fix readme --- README.md | 229 +++++++----------------- docs/Documentation-CHN/QuickStart.md | 2 +- docs/Documentation/QuickStart.md | 330 +++++++++-------------------------- 3 files changed, 139 insertions(+), 422 deletions(-) diff --git a/README.md b/README.md index f622582..cd3f5c6 100644 --- a/README.md +++ b/README.md @@ -62,113 +62,39 @@ If you want to use Hadoop or Spark to analyze IoTDB data file (called as TsFile) This short guide will walk you through the basic process of using IoTDB. For a more-complete guide, please visit our website's [User Guide](https://iotdb.apache.org/#/Documents/0.8.0/chap1/sec1). -## Installation from source code +## Get source code -You can get the released source code from https://iotdb.apache.org/#/Download, or from the git repository https://github.com/apache/incubator-iotdb/tree/master +* https://iotdb.apache.org/#/Download +* https://github.com/apache/incubator-iotdb/tree/master -Now suppose your directory is like this: +## Build from source ``` -> pwd -/workspace/incubator-iotdb - -> ls -l -incubator-iotdb/ <-- root path -| -+- server/ -| -+- jdbc/ -| -+- tsfile/ -| -... -| -+- pom.xml +> mvn clean package -Papache-release -DskipTests ``` -Let `$IOTDB_HOME = /workspace/incubator-iotdb/server/target/iotdb-server-{project.version}` +Then the binary version (including both server and client) can be found at **distribution/target/apache-iotdb-{project.version}-incubating-bin.zip** -Let `$IOTDB_CLI_HOME = /workspace/incubator-iotdb/client/target/iotdb-client-{project.version}` +> NOTE: Directories "service-rpc/target/generated-sources/thrift" and "server/target/generated-sources/antlr3" need to be added to sources roots to avoid compilation errors in IDE. -Note: -* if `IOTDB_HOME` is not explicitly assigned, -then by default `IOTDB_HOME` is the direct parent directory of `sbin/start-server.sh` on Unix/OS X -(or that of `sbin\start-server.bat` on Windows). +### Configurations -* if `IOTDB_CLI_HOME` is not explicitly assigned, -then by default `IOTDB_CLI_HOME` is the direct parent directory of `sbin/start-cli.sh` on -Unix/OS X (or that of `sbin\start-cli.bat` on Windows). +configuration files are under "conf" folder -If you are not the first time that building IoTDB, remember deleting the following files: + * environment config module (`iotdb-env.bat`, `iotdb-env.sh`), + * system config module (`tsfile-format.properties`, `iotdb-engine.properties`) + * log config module (`logback.xml`). -``` -> rm -rf $IOTDB_HOME/data/ -> rm -rf $IOTDB_HOME/lib/ -``` - -Then under the root path of incubator-iotdb, you can build IoTDB using Maven: - -``` -> pwd -/workspace/incubator-iotdb - -> mvn clean package -pl server -am -Dmaven.test.skip=true -``` +For more, see [Chapter4: Deployment and Management](https://iotdb.apache.org/#/Documents/0.8.0/chap4/sec1) in detail. -If successful, you will see the the following text in the terminal: - -``` -[INFO] ------------------------------------------------------------------------ -[INFO] Reactor Summary: -[INFO] -[INFO] Apache IoTDB (incubating) Project Parent POM ....... SUCCESS [ 6.405 s] -[INFO] TsFile ............................................. SUCCESS [ 10.435 s] -[INFO] Service-rpc ........................................ SUCCESS [ 4.170 s] -[INFO] IoTDB Jdbc ......................................... SUCCESS [ 3.252 s] -[INFO] IoTDB Server ....................................... SUCCESS [ 8.072 s] -[INFO] ------------------------------------------------------------------------ -[INFO] BUILD SUCCESS -[INFO] ------------------------------------------------------------------------ -``` - -Otherwise, you may need to check the error statements and fix the problems. - -After build, the IoTDB project will be at the folder "server/target/iotdb-server-{project.version}". The folder will include the following contents: - -``` -server/target/iotdb-server-{project.version} <-- root path -| -+- sbin/ <-- script files for starting and stopping the server -| -+- tools/ <-- script files of tools -| -+- conf/ <-- configuration files -| -+- lib/ <-- project dependencies -``` - -> NOTE: Directories "service-rpc/target/generated-sources/thrift" and "server/target/generated-sources/antlr3" need to be added to sources roots to avoid compilation errors. - -## Configure - -Before starting to use IoTDB, you need to config the configuration files first. For your convenience, we have already set the default config in the files. - -In total, we provide users three kinds of configurations module: environment config module (`iotdb-env.bat`, `iotdb-env.sh`), system config module (`tsfile-format.properties`, `iotdb-engine.properties`) and log config module (`logback.xml`). All of these kinds of configuration files are put in iotdb/config folder. - -For more, you are advised to check our documentation [Chapter4: Deployment and Management](https://iotdb.apache.org/#/Documents/0.8.0/chap4/sec1) in detail. - -## Start - -### Start Server - -After that we start the server. Running the startup script: +### Start server ``` # Unix/OS X -> $IOTDB_HOME/sbin/start-server.sh +> sbin/start-server.sh # Windows -> $IOTDB_HOME\sbin\start-server.bat +> sbin\start-server.bat ``` ### Stop Server @@ -177,92 +103,40 @@ The server can be stopped with ctrl-C or the following script: ``` # Unix/OS X -> $IOTDB_HOME/sbin/stop-server.sh +> sbin/stop-server.sh # Windows -> $IOTDB_HOME\sbin\stop-server.bat -``` - -### Start Client - -Now let's trying to read and write some data from IoTDB using our Client. To start the client, you need to explicit the server's IP and PORT as well as the USER_NAME and PASSWORD. - -``` -# You can first build cli project -> pwd -/workspace/incubator-iotdb - -> mvn clean package -pl client -am -Dmaven.test.skip=true +> sbin\stop-server.bat ``` -After build, the IoTDB client will be at the folder "client/target/iotdb-client-{project.version}". +### Using client ``` # Unix/OS X -> $IOTDB_CLI_HOME/sbin/start-cli.sh -h <IP> -p <PORT> -u <USER_NAME> +> sbin/start-cli.sh -h <IP> -p <PORT> -u <USER_NAME> # Windows -> $IOTDB_CLI_HOME\sbin\start-cli.bat -h <IP> -p <PORT> -u <USER_NAME> +> sbin\start-cli.bat -h <IP> -p <PORT> -u <USER_NAME> ``` -> NOTE: In the system, we set a default user in IoTDB named 'root'. The default password for 'root' is 'root'. You can use this default user if you are making the first try or you didn't create users by yourself. +> The default user is 'root'. The default password for 'root' is 'root'. -The command line client is interactive so if everything is ready you should see the welcome logo and statements: - -``` - _____ _________ ______ ______ -|_ _| | _ _ ||_ _ `.|_ _ \ - | | .--.|_/ | | \_| | | `. \ | |_) | - | | / .'`\ \ | | | | | | | __'. - _| |_| \__. | _| |_ _| |_.' /_| |__) | -|_____|'.__.' |_____| |______.'|_______/ version x.x.x - - -IoTDB> login successfully -IoTDB> -``` -### Have a try -Now, you can use IoTDB SQL to operate IoTDB, and when you've had enough fun, you can input 'quit' or 'exit' command to leave the client. - -But lets try something slightly more interesting: +> The default parameters are "-h 127.0.0.1 -p 6667 -u root -pw root". ``` -IoTDB> SET STORAGE GROUP TO root.vehicle -It costs xxxs -IoTDB> CREATE TIMESERIES root.vehicle.d0.s0 WITH DATATYPE=INT32, ENCODING=RLE -It costs xxxs -``` -Till now, we have already create a table called root.vehicle and add a column called d0.s0 in the table. Let's take a look at what we have done by 'SHOW TIMESERIES' command. +IoTDB> set storage group to root.vehicle -``` -IoTDB> SHOW TIMESERIES -=== Timeseries Tree === - -{ - "root":{ - "vehicle":{ - "d0":{ - "s0":{ - "args":"{}", - "StorageGroup":"root.vehicle", - "DataType":"INT32", - "Compressor":"UNCOMPRESSED", - "Encoding":"RLE" - } - } - } - } -} -``` -Insert time series data is the basic operation of IoTDB, you can use 'INSERT' command to finish this: +IoTDB> create timeseries root.vehicle.d0.s0 with datatype=INT32, encoding=RLE + +IoTDB> show timeseries root ++-----------------------------+---------------------+--------+--------+ +| Timeseries| Storage Group|DataType|Encoding| ++-----------------------------+---------------------+--------+--------+ +| root.vehicle.d0.s0| root.vehicle| INT32| RLE| ++-----------------------------+---------------------+--------+--------+ -``` IoTDB> insert into root.vehicle.d0(timestamp,s0) values(1,101); -It costs xxxs -``` -The data we've just inserted displays like this: -``` IoTDB> SELECT d0.s0 FROM root.vehicle +-----------------------------+------------------+ | Time|root.vehicle.d0.s0| @@ -270,15 +144,13 @@ IoTDB> SELECT d0.s0 FROM root.vehicle |1970-01-01T08:00:00.001+08:00| 101| +-----------------------------+------------------+ Total line number = 1 -It costs xxxs -``` -If your session looks similar to what's above, congrats, your IoTDB is operational! - -For more on what commands are supported by IoTDB SQL, see our documentation [Chapter 5: IoTDB SQL Documentation](https://iotdb.apache.org/#/Documents/0.8.0/chap5/sec1). +IoTDB> quit/exit +``` +For more on what commands are supported by IoTDB SQL, see [Chapter 5: IoTDB SQL Documentation](https://iotdb.apache.org/#/Documents/0.8.0/chap5/sec1). -# Usage of import-csv.sh +### Usage of import-csv.sh ### Create metadata ``` @@ -295,10 +167,10 @@ CREATE TIMESERIES root.fit.p.s1 WITH DATATYPE=INT32,ENCODING=RLE; ### Run import shell ``` # Unix/OS X -> $IOTDB_CLI_HOME/tools/import-csv.sh -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> +> tools/import-csv.sh -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> # Windows -> $IOTDB_CLI_HOME\tools\import-csv.bat -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> +> tools\import-csv.bat -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> ``` ### Error data file @@ -310,8 +182,27 @@ CREATE TIMESERIES root.fit.p.s1 WITH DATATYPE=INT32,ENCODING=RLE; ### Run export shell ``` # Unix/OS X -> $IOTDB_CLI_HOME/tools/export-csv.sh -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] +> tools/export-csv.sh -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] # Windows -> $IOTDB_CLI_HOME\tools\export-csv.bat -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] -``` \ No newline at end of file +> tools\export-csv.bat -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] +``` + +## Only build server + +Under the root path of incubator-iotdb: + +``` +> mvn clean package -pl server -am -DskipTests=true +``` + +After build, the IoTDB server will be at the folder "server/target/iotdb-server-{project.version}". + + +## Only build client + +``` +> mvn clean package -pl client -am -DskipTests=true +``` + +After build, the IoTDB client will be at the folder "client/target/iotdb-client-{project.version}". \ No newline at end of file diff --git a/docs/Documentation-CHN/QuickStart.md b/docs/Documentation-CHN/QuickStart.md index 4d189d0..9768404 100755 --- a/docs/Documentation-CHN/QuickStart.md +++ b/docs/Documentation-CHN/QuickStart.md @@ -41,7 +41,7 @@ 安装前需要保证设备上配有JDK>=1.8的运行环境,并配置好JAVA_HOME环境变量。 -如需从源码进行编译,还需要Maven>=3.0的运行环境。 +如需从源码进行编译,还需要Maven>=3.1的运行环境。 ## IoTDB安装 diff --git a/docs/Documentation/QuickStart.md b/docs/Documentation/QuickStart.md index d36489a..74160cd 100755 --- a/docs/Documentation/QuickStart.md +++ b/docs/Documentation/QuickStart.md @@ -35,326 +35,152 @@ - Stop Server <!-- /TOC --> -# Quick Start - -This short guide will walk you through the basic process of using IoTDB. For a more-complete guide, please visit our website’s documents. - -## Prerequisites - -To use IoTDB, you need to have: -1. Java >= 1.8 (Please make sure the environment path has been set) -2. Maven >= 3.0 (If you want to compile and install IoTDB from source code) - -## Installation - -IoTDB provides you two installation methods, you can refer to the following suggestions, choose one of them: - -* Installation from source code. If you need to modify the code yourself, you can use this method. -* Installation from binary files. Download the binary files from the official website. This is the recommended method, in which you will get a binary released package which is out-of-the-box.(Comming Soon...) +# Quick Start -Here in the Quick Start, we give a brief introduction of using source code to install IoTDB. For further information, please refer to Chapter 4 of the User Guide. +This short guide will walk you through the basic process of using IoTDB. For a more-complete guide, please visit our website's [User Guide](https://iotdb.apache.org/#/Documents/0.8.0/chap1/sec1). -### Installation from source code +## Get source code -You can get the released source code from https://iotdb.apache.org/#/Download, or from the git repository https://github.com/apache/incubator-iotdb/tree/master +* https://iotdb.apache.org/#/Download +* https://github.com/apache/incubator-iotdb/tree/master -Now suppose your directory is like this: +## Build from source ``` -> pwd -/workspace/incubator-iotdb - -> ls -l -incubator-iotdb/ <-- root path -| -+- server/ -| -+- jdbc/ -| -+- client/ -| -... -| -+- pom.xml +> mvn clean package -Papache-release -DskipTests ``` -Let `$IOTDB_HOME = /workspace/incubator-iotdb/server/target/iotdb-server-{project.version}` +Then the binary version (including both server and client) can be found at **distribution/target/apache-iotdb-{project.version}-incubating-bin.zip** -Let `$IOTDB_CLI_HOME = /workspace/incubator-iotdb/client/target/iotdb-client-{project.version}` +> NOTE: Directories "service-rpc/target/generated-sources/thrift" and "server/target/generated-sources/antlr3" need to be added to sources roots to avoid compilation errors in IDE. -Note: -* if `IOTDB_HOME` is not explicitly assigned, -then by default `IOTDB_HOME` is the direct parent directory of `sbin/start-server.sh` on Unix/OS X -(or that of `sbin\start-server.bat` on Windows). +### Configurations -* if `IOTDB_CLI_HOME` is not explicitly assigned, -then by default `IOTDB_CLI_HOME` is the direct parent directory of `sbin/start-cli.sh` on -Unix/OS X (or that of `sbin\start-cli.bat` on Windows). +configuration files are under "conf" folder -If you are not the first time that building IoTDB, remember deleting the following files: + * environment config module (`iotdb-env.bat`, `iotdb-env.sh`), + * system config module (`tsfile-format.properties`, `iotdb-engine.properties`) + * log config module (`logback.xml`). -``` -> rm -rf $IOTDB_HOME/data/ -> rm -rf $IOTDB_HOME/lib/ -``` +For more, see [Chapter4: Deployment and Management](https://iotdb.apache.org/#/Documents/0.8.0/chap4/sec1) in detail. -Then under the root path of incubator-iotdb, you can build IoTDB using Maven: +### Start server ``` -> pwd -/workspace/incubator-iotdb - # Unix/OS X -> mvn clean package -pl server -am -Dmaven.test.skip=true +> sbin/start-server.sh # Windows -> mvn clean package -pl server -am '-Dmaven.test.skip=true' +> sbin\start-server.bat ``` -Note: If you are a Windows user, you should use quoting `'-Dmaven.test.skip=true'` in the following commands. - -If successful, you will see the the following text in the terminal: - -``` -[INFO] ------------------------------------------------------------------------ -[INFO] Reactor Summary: -[INFO] -[INFO] Apache IoTDB (incubating) Project Parent POM ....... SUCCESS [ 6.405 s] -[INFO] TsFile ............................................. SUCCESS [ 10.435 s] -[INFO] Service-rpc ........................................ SUCCESS [ 4.170 s] -[INFO] IoTDB Jdbc ......................................... SUCCESS [ 3.252 s] -[INFO] IoTDB Server ....................................... SUCCESS [ 8.072 s] -[INFO] ------------------------------------------------------------------------ -[INFO] BUILD SUCCESS -[INFO] ------------------------------------------------------------------------ -``` - -Otherwise, you may need to check the error statements and fix the problems. - -After building, the IoTDB project will be at the subfolder named iotdb. The folder will include the following contents: - -``` -$IOTDB_HOME/ -| -+- sbin/ <-- script files -| -+- conf/ <-- configuration files -| -+- lib/ <-- project dependencies -``` - -## Configure - -Before starting to use IoTDB, you need to config the configuration files first. For your convenience, we have already set the default config in the files. - -In total, we provide users three kinds of configurations module: - -* environment config module (`iotdb-env.sh`(Linux or OSX), `iotdb-env.bat`(Windows)) -* system config module (`tsfile-format.properties`, `iotdb-engine.properties`) -* log config module (`logback.xml`) - -The configuration files of the three configuration items are located in the IoTDB installation directory: `$IOTDB_HOME/conf` folder. For more, you are advised to check Chapter 4 of the User Guide to give you the details. - -## Start - -### Start Server +### Stop Server -After that we start the server. Running the startup script: +The server can be stopped with ctrl-C or the following script: ``` # Unix/OS X -> $IOTDB_HOME/sbin/start-server.sh +> sbin/stop-server.sh # Windows -> $IOTDB_HOME\sbin\start-server.bat +> sbin\stop-server.bat ``` -### Start Cli - -Now let's trying to read and write some data from IoTDB using our Cli. To start the client, you need to explicit the server's IP and PORT as well as the USER_NAME and PASSWORD. +### Using client ``` -# You can first build cli project -> pwd -/workspace/incubator-iotdb - -> mvn clean package -pl client -am -Dmaven.test.skip=true - # Unix/OS X -> $IOTDB_CLI_HOME/sbin/start-cli.sh -h <IP> -p <PORT> -u <USER_NAME> +> sbin/start-cli.sh -h <IP> -p <PORT> -u <USER_NAME> # Windows -> $IOTDB_CLI_HOME\sbin\start-cli.bat -h <IP> -p <PORT> -u <USER_NAME> +> sbin\start-cli.bat -h <IP> -p <PORT> -u <USER_NAME> ``` -> NOTE: In the system, we set a default user in IoTDB named 'root'. The default password for 'root' is 'root'. You can use this default user if you are making the first try or you didn't create users by yourself. - -The command line client is interactive so if everything is ready you should see the welcome logo and statements: - -``` - _____ _________ ______ ______ -|_ _| | _ _ ||_ _ `.|_ _ \ - | | .--.|_/ | | \_| | | `. \ | |_) | - | | / .'`\ \ | | | | | | | __'. - _| |_| \__. | _| |_ _| |_.' /_| |__) | -|_____|'.__.' |_____| |______.'|_______/ version x.x.x +> The default user is 'root'. The default password for 'root' is 'root'. +> The default parameters are "-h 127.0.0.1 -p 6667 -u root -pw root". -IoTDB> login successfully -IoTDB> -``` +``` +IoTDB> set storage group to root.vehicle +IoTDB> create timeseries root.vehicle.d0.s0 with datatype=INT32, encoding=RLE -### Have a try +IoTDB> show timeseries root ++-----------------------------+---------------------+--------+--------+ +| Timeseries| Storage Group|DataType|Encoding| ++-----------------------------+---------------------+--------+--------+ +| root.vehicle.d0.s0| root.vehicle| INT32| RLE| ++-----------------------------+---------------------+--------+--------+ -Now, you can use IoTDB SQL to operate IoTDB, and when you’ve had enough fun, you can input 'quit' or 'exit' command to leave the client. +IoTDB> insert into root.vehicle.d0(timestamp,s0) values(1,101); -But lets try something slightly more interesting: +IoTDB> SELECT d0.s0 FROM root.vehicle ++-----------------------------+------------------+ +| Time|root.vehicle.d0.s0| ++-----------------------------+------------------+ +|1970-01-01T08:00:00.001+08:00| 101| ++-----------------------------+------------------+ +Total line number = 1 -``` -IoTDB> SET STORAGE GROUP TO root.ln -execute successfully. -IoTDB> CREATE TIMESERIES root.ln.wf01.wt01.status WITH DATATYPE=BOOLEAN, ENCODING=PLAIN -execute successfully. +IoTDB> quit/exit ``` -Till now, we have already create a table called root.vehicle and add a column called d0.s0 in the table. Let's take a look at what we have done by 'SHOW TIMESERIES' command. -``` -IoTDB> SHOW TIMESERIES -=== Timeseries Tree === - -{ - "root":{ - "ln":{ - "wf01":{ - "wt01":{ - "status":{ - "args":"{}", - "StorageGroup":"root.ln", - "DataType":"BOOLEAN", - "Compressor":"UNCOMPRESSED", - "Encoding":"PLAIN" - } - } - } - } - } -} -``` +For more on what commands are supported by IoTDB SQL, see [Chapter 5: IoTDB SQL Documentation](https://iotdb.apache.org/#/Documents/0.8.0/chap5/sec1). -For a further try, create a timeseries again and use SHOW TIMESERIES to check result. +### Usage of import-csv.sh +### Create metadata ``` -IoTDB> CREATE TIMESERIES root.ln.wf01.wt01.temperature WITH DATATYPE=FLOAT, ENCODING=RLE -IoTDB> SHOW TIMESERIES -=== Timeseries Tree === - -{ - "root":{ - "ln":{ - "wf01":{ - "wt01":{ - "temperature":{ - "args":"{}", - "StorageGroup":"root.ln", - "DataType":"FLOAT", - "Compressor":"UNCOMPRESSED", - "Encoding":"RLE" - }, - "status":{ - "args":"{}", - "StorageGroup":"root.ln", - "DataType":"BOOLEAN", - "Compressor":"UNCOMPRESSED", - "Encoding":"PLAIN" - } - } - } - } - } -} +SET STORAGE GROUP TO root.fit.d1; +SET STORAGE GROUP TO root.fit.d2; +SET STORAGE GROUP TO root.fit.p; +CREATE TIMESERIES root.fit.d1.s1 WITH DATATYPE=INT32,ENCODING=RLE; +CREATE TIMESERIES root.fit.d1.s2 WITH DATATYPE=TEXT,ENCODING=PLAIN; +CREATE TIMESERIES root.fit.d2.s1 WITH DATATYPE=INT32,ENCODING=RLE; +CREATE TIMESERIES root.fit.d2.s3 WITH DATATYPE=INT32,ENCODING=RLE; +CREATE TIMESERIES root.fit.p.s1 WITH DATATYPE=INT32,ENCODING=RLE; ``` -Now, for your conveniect, SHOW TIMESERIES clause also supports extention syntax, the pattern is (for further details, check Chapter 5 of the User Guide): +### Run import shell ``` -SHOW TIMESERIES <PATH> -``` - -Here is the example: +# Unix/OS X +> tools/import-csv.sh -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> +# Windows +> tools\import-csv.bat -h <ip> -p <port> -u <username> -pw <password> -f <xxx.csv> ``` -IoTDB> SHOW TIMESERIES root.ln.wf01.wt01 -+------------------------------+--------------+--------+--------+ -| Timeseries| Storage Group|DataType|Encoding| -+------------------------------+--------------+--------+--------+ -| root.ln.wf01.wt01.status| root.ln| BOOLEAN| PLAIN| -| root.ln.wf01.wt01.temperature| root.ln| FLOAT| RLE| -+------------------------------+--------------+--------+--------+ -Total timeseries number = 2 -Execute successfully. -``` -We can also use SHOW STORAGE GROUP to check created storage group: -``` -IoTDB> show storage group -+-----------------------------------+ -| Storage Group| -+-----------------------------------+ -| root.ln| -+-----------------------------------+ -Total storage group number = 1 -Execute successfully. -It costs 0.006s -``` +### Error data file +`csvInsertError.error` -Insert timeseries data is the basic operation of IoTDB, you can use 'INSERT' command to finish this: +# Usage of export-csv.sh +### Run export shell ``` -IoTDB> INSERT INTO root.ln.wf01.wt01(timestamp,status) values(100,true); -execute successfully. -IoTDB> INSERT INTO root.ln.wf01.wt01(timestamp,status,temperature) values(200,false,20.71) execute successfully. -``` -The data we've just inserted displays like this: +# Unix/OS X +> tools/export-csv.sh -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] -``` -IoTDB> SELECT status FROM root.ln.wf01.wt01 -+-----------------------+------------------------+ -| Time|root.ln.wf01.wt01.status| -+-----------------------+------------------------+ -|1970-01-01T08:00:00.100| true| -|1970-01-01T08:00:00.200| false| -+-----------------------+------------------------+ -record number = 1 -execute successfully. +# Windows +> tools\export-csv.bat -h <ip> -p <port> -u <username> -pw <password> -td <xxx.csv> [-tf <time-format>] ``` -We can also query several timeseries data at once like this: +## Only build server + +Under the root path of incubator-iotdb: ``` -IoTDB> SELECT * FROM root.ln.wf01.wt01 -+-----------------------+--------------------------+-----------------------------+ -| Time| root.ln.wf01.wt01.status|root.ln.wf01.wt01.temperature| -+-----------------------+--------------------------+-----------------------------+ -|1970-01-01T08:00:00.100| true| null| -|1970-01-01T08:00:00.200| false| 20.71| -+-----------------------+--------------------------+-----------------------------+ +> mvn clean package -pl server -am -DskipTests=true ``` -If your session looks similar to what’s above, congrats, your IoTDB is operational! - -For more on what commands are supported by IoTDB SQL, see Chapter 5 of the User Guide. It will give you help. +After build, the IoTDB server will be at the folder "server/target/iotdb-server-{project.version}". + -### Stop Server - -The server can be stopped with ctrl-C or the following script: +## Only build client ``` -# Unix/ OS X -> $IOTDB_HOME/bin/stop-server.sh - -# Windows -> $IOTDB_HOME\bin\stop-server.bat +> mvn clean package -pl client -am -DskipTests=true ``` +After build, the IoTDB client will be at the folder "client/target/iotdb-client-{project.version}". \ No newline at end of file
