diff --git a/docs-2.0/2.quick-start/4.nebula-graph-crud.md b/docs-2.0/2.quick-start/4.nebula-graph-crud.md index cb25c4a10d9..6bf06b137d7 100644 --- a/docs-2.0/2.quick-start/4.nebula-graph-crud.md +++ b/docs-2.0/2.quick-start/4.nebula-graph-crud.md @@ -12,12 +12,12 @@ A Nebula Graph instance consists of one or more graph spaces. Graph spaces are p To insert data into a graph space, define a schema for the graph database. Nebula Graph schema is based on the following components. -| Schema component | Description | -| ---------------- | --------------------------------------------------------------------------------------- | -| Vertex | Represents an entity in the real world. A vertex can have one or more tags. | +| Schema component | Description | +| ---------------- | ------------| +| Vertex | Represents an entity in the real world. A vertex can have one or more tags. | | Tag | The type of the same group of vertices. It defines a set of properties that describes the types of vertices. | -| Edge | Represents a **directed** relationship between two vertices. | -| Edge type | The type of an edge. It defines a group of properties that describes the types of edges. | +| Edge | Represents a **directed** relationship between two vertices. | +| Edge type | The type of an edge. It defines a group of properties that describes the types of edges. | For more information, see [Data modeling](../1.introduction/2.data-model.md). @@ -43,13 +43,13 @@ nebula> SHOW HOSTS; +-------------+-----------+-----------+--------------+----------------------+------------------------+ ``` -From the **Status** column of the table in the return results, you can see that all the Storage services are online. +From the **Status** column of the table in the returned results, you can see that all the Storage services are online. -### Asynchronous implementation of creation and alteration +### Async implementation of `CREATE` and `ALTER` !!! caution - Nebula Graph implements the following creation or alteration operations asynchronously in the **next** heartbeat cycle. The operations will not take effect until they finish. + In Nebula Graph, the following `CREATE` or `ALTER` commands are implemented in an async way and take effect in the **next** heartbeat cycle. Otherwise, an error will be returned. * `CREATE SPACE` * `CREATE TAG` @@ -65,7 +65,7 @@ From the **Status** column of the table in the return results, you can see that To make sure the follow-up operations work as expected, take one of the following approaches: -* Run `SHOW` or `DESCRIBE` statements accordingly to check the status of the objects, and make sure the creation or alteration is complete. If it is not, wait a few seconds and try again. +* Run `SHOW` or `DESCRIBE` statements accordingly to check the status of the objects, and make sure the creation or alteration is complete. If it is not, wait for a few seconds and try again. * Wait for two heartbeat cycles, i.e., 20 seconds. @@ -158,7 +158,7 @@ For more information on parameters, see [CREATE TAG](../3.ngql-guide/10.tag-stat ### Examples -Create tags `player` and `team`, edge types `follow` and `serve`. Descriptions are as follows. +Create tags `player` and `team`, and edge types `follow` and `serve`. Descriptions are as follows. | Component name | Type | Property | | :--- | :--- | :--- | @@ -179,7 +179,7 @@ nebula> CREATE EDGE serve(start_year int, end_year int); ## Insert vertices and edges -Users can use the `INSERT` statement to insert vertices or edges based on existing tags or edge types. +You can use the `INSERT` statement to insert vertices or edges based on existing tags or edge types. ### nGQL syntax @@ -320,7 +320,7 @@ Users can use the `INSERT` statement to insert vertices or edges based on existi | `$$` | Represents the target vertices. | | `\` | A line-breaker. | -* Search for the players that the player with VID `player101` follows. Then Retrieve the teams of the players that the player with VID `player100` follows. To combine the two queries, use a pipe or a temporary variable. +* Search for the players that the player with VID `player101` follows. Then retrieve the teams of the players that the player with VID `player100` follows. To combine the two queries, use a pipe or a temporary variable. * With a pipe: diff --git a/docs-2.0/reuse/source_connect-to-nebula-graph.md b/docs-2.0/reuse/source_connect-to-nebula-graph.md index 21f56ab3b50..27d0f881b50 100644 --- a/docs-2.0/reuse/source_connect-to-nebula-graph.md +++ b/docs-2.0/reuse/source_connect-to-nebula-graph.md @@ -4,16 +4,17 @@ Nebula Graph supports multiple types of clients, including a CLI client, a GUI c You can use supported [clients or console](https://docs.nebula-graph.io/{{nebula.release}}/20.appendix/6.eco-tool-version/) to connect to Nebula Graph. - ## Use Nebula Console to connect to Nebula Graph ### Prerequisites -* You have started the Nebula Graph services. For how to start the services, see [Start and Stop Nebula Graph](https://docs.nebula-graph.io/{{nebula.release}}/4.deployment-and-installation/manage-service/). -* The machine you plan to run Nebula Console on has network access to the Nebula Graph services. +* You have started [Nebula Graph services](https://docs.nebula-graph.io/{{nebula.release}}/4.deployment-and-installation/manage-service/). + +* The machine you plan to run Nebula Console on has network access to Nebula Graph services. ### Steps @@ -63,9 +64,9 @@ If you don't have a Nebula Graph database yet, we recommend that you try the clo [-t 120] [-e "nGQL_statement" | -f filename.nGQL] ``` - The description of the parameters is as follows. + Parameters and descriptions are as follows. - | Option | Description | + | Parameter | Description | | - | - | | `-h` | Shows the help menu. | | `-addr` | Sets the IP address of the graphd service. The default address is 127.0.0.1. | @@ -74,13 +75,13 @@ If you don't have a Nebula Graph database yet, we recommend that you try the clo | `-p/-password` | Sets the password of your Nebula Graph account. Before enabling authentication, you can use any characters as the password. | | `-t/-timeout` | Sets an integer-type timeout threshold of the connection. The unit is second. The default value is 120. | | `-e/-eval` | Sets a string-type nGQL statement. The nGQL statement is executed once the connection succeeds. The connection stops after the result is returned. | - | `-f/-file` | Sets the path of an nGQL file. The nGQL statements in the file are executed once the connection succeeds. You'll get the return messages and the connection stops then. | + | `-f/-file` | Sets the path of an nGQL file. The nGQL statements in the file are executed once the connection succeeds. The result will be returned and the connection stops then. | You can find more details in the [Nebula Console Repository](https://github.com/vesoft-inc/nebula-console/tree/{{console.branch}}). ## Nebula Console commands -Nebula Console can export CSV file, DOT file, and import too. +Nebula Console can export CSV file, DOT file, and import datasets. !!! note @@ -88,15 +89,15 @@ Nebula Console can export CSV file, DOT file, and import too. ### Export a CSV file -CSV files save the return result of a executed command. +CSV files save the returned result of a executed command. !!! note - - A CSV file will be saved in the working directory, i.e., what linux command `pwd` show; + - A CSV file will be saved in the working directory, i.e., what the linux command `pwd` shows. - This command only works for the next query statement. -The command to export a csv file. +The command to export a csv file is as follows: ```ngql nebula> :CSV @@ -104,34 +105,34 @@ nebula> :CSV ### Export a DOT file -DOT files save the return result of a executed command, and the result information is different from CSV files. +DOT files save the returned result of a executed command, and the resulted information is different from that of CSV files. !!! Note - - A DOT file will be saved in the working directory, i.e., what linux command `pwd` show; + - A DOT file will be saved in the working directory, i.e., what the linux command `pwd` shows. - - You can copy the contents of DOT file, and paste in [GraphvizOnline](https://dreampuf.github.io/GraphvizOnline/), to visualize the excution plan; + - You can copy the contents of the DOT file and paste them in [GraphvizOnline](https://dreampuf.github.io/GraphvizOnline/) to generate a visualized execution plan. - This command only works for the next query statement. -The command to export a DOT file. +The command to export a DOT file is as follows: ```ngql nebula> :dot ``` -For example, +The example is as follows: ```ngql nebula> :dot a.dot nebula> PROFILE FORMAT="dot" GO FROM "player100" OVER follow; ``` -### Importing a testing dataset +### Import a testing dataset -The testing dataset is named `nba`. Details about schema and data can be seen by commands `SHOW`. +The testing dataset is named `nba`. To view details about the schema and data, use the corresponding `SHOW` command. -Using the following command to import the testing dataset, +The command to import a testing dataset is as follows: ```ngql nebula> :play nba @@ -139,13 +140,13 @@ nebula> :play nba ### Run a command multiple times -Sometimes, you want to run a command multiple times. Run the following command. +To run a command multiple times, use the following command: ```ngql nebula> :repeat N ``` -For example, +The example is as follows: ```ngql nebula> :repeat 3 @@ -185,9 +186,7 @@ Executed 3 times, (total time spent 3681/4734 us), (average time spent 1227/1578 ### Sleep to wait -Sleep N seconds. - -It is usually used when altering schema. Since schema is altered in async way, and take effects in the next heartbeat cycle. +This command will make Nebula Graph services sleep and wait for N seconds. The schema is altered in an async way and takes effect in the next heartbeat cycle. Therefore, this command is usually used when altering schema. The command is as follows: ```ngql nebula> :sleep N @@ -197,6 +196,8 @@ nebula> :sleep N You can use `:EXIT` or `:QUIT` to disconnect from Nebula Graph. For convenience, Nebula Console supports using these commands in lower case without the colon (":"), such as `quit`. +The example is as follows: + ```ngql nebula> :QUIT @@ -205,6 +206,6 @@ Bye root! ## FAQ -### How can I install Nebula Console from the source code +### "How can I install Nebula Console from the source code?" To download and compile the latest source code of Nebula Console, follow the instructions on [the nebula console GitHub page](https://github.com/vesoft-inc/nebula-console#build-nebula-graph-console). diff --git a/docs-2.0/reuse/source_install-nebula-graph-by-rpm-or-deb.md b/docs-2.0/reuse/source_install-nebula-graph-by-rpm-or-deb.md index b771ae48718..f3528b956fa 100644 --- a/docs-2.0/reuse/source_install-nebula-graph-by-rpm-or-deb.md +++ b/docs-2.0/reuse/source_install-nebula-graph-by-rpm-or-deb.md @@ -10,7 +10,7 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. !!! enterpriseonly - For the Enterprise Edition, please send an email to inquiry@vesoft.com. + For the Enterprise Edition, please send email to inquiry@vesoft.com. ## Download the package from cloud service @@ -38,14 +38,14 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. https://oss-cdn.nebula-graph.io/package//nebula-graph-.ubuntu2004.amd64.deb ``` - For example, download release package {{ nebula.release }} for `Centos 7.5`: + For example, download the release package `{{ nebula.release }}` for `Centos 7.5`: ```bash wget https://oss-cdn.nebula-graph.io/package/{{ nebula.release }}/nebula-graph-{{ nebula.release }}.el7.x86_64.rpm wget https://oss-cdn.nebula-graph.io/package/{{ nebula.release }}/nebula-graph-{{ nebula.release }}.el7.x86_64.rpm.sha256sum.txt ``` - download release package `{{ nebula.release }}` for `Ubuntu 1804`: + Download the release package `{{ nebula.release }}` for `Ubuntu 1804`: ```bash wget https://oss-cdn.nebula-graph.io/package/{{ nebula.release }}/nebula-graph-{{ nebula.release }}.ubuntu1804.amd64.deb @@ -56,8 +56,8 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. !!! danger - - Nightly versions are usually used to test new features. Don't use it for production. - - Nightly versions may not be build successfully every night. And the names may change from day to day. + - Nightly versions are usually used to test new features. Do not use it in a production environment. + - Nightly versions may not be built successfully every night. And the names may change from day to day. URL: @@ -94,14 +94,14 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. wget https://oss-cdn.nebula-graph.io/package/nightly/2021.11.28/nebula-graph-2021.11.28-nightly.ubuntu1804.amd64.deb wget https://oss-cdn.nebula-graph.io/package/nightly/2021.11.28/nebula-graph-2021.11.28-nightly.ubuntu1804.amd64.deb.sha256sum.txt ``` + @@ -129,7 +130,7 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. ```bash sudo rpm -ivh nebula-graph-{{nebula.release}}.el7.x86_64.rpm - ``` + ``` * Use the following syntax to install with a DEB package. @@ -147,8 +148,10 @@ Prepare the right [resources](https://docs.nebula-graph.io/{{nebula.release}}/4. The default installation path is `/usr/local/nebula/`. -## What's next +## Next to do - (Enterprise Edition)[Deploy license](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/deploy-license) -- [start Nebula Graph](https://docs.nebula-graph.io/{{nebula.release}}/2.quick-start/5.start-stop-service/) -- [connect to Nebula Graph](https://docs.nebula-graph.io/{{nebula.release}}/2.quick-start/3.connect-to-nebula-graph/) + +- [Start Nebula Graph](https://docs.nebula-graph.io/{{nebula.release}}/2.quick-start/5.start-stop-service/) + +- [Connect to Nebula Graph](https://docs.nebula-graph.io/{{nebula.release}}/2.quick-start/3.connect-to-nebula-graph/)