Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: publish 0.9.2 #1142

Merged
merged 3 commits into from
Aug 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/getting-started/installation/greptimedb-standalone.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ You can:

1. Set `--security-opt seccomp=unconfined`, for example:

```shell
```shell
docker run --security-opt seccomp=unconfined -p 4000-4003:4000-4003 \
-v "$(pwd)/greptimedb:/tmp/greptimedb" \
--name greptime --rm \
Expand All @@ -77,7 +77,7 @@ You can:
--rpc-addr 0.0.0.0:4001 \
--mysql-addr 0.0.0.0:4002 \
--postgres-addr 0.0.0.0:4003
```
```

2. Upgrade the Docker version to v23.0.0 or higher;
:::
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ You can find the GreptimeDB URL, database name, as well as the username and pass

<TabItem value="InfluxDB line protocol v2" label="InfluxDB line protocol v2">

```shell
```shell
curl -X POST 'https://<host>/v1/influxdb/api/v2/write?bucket=<db-name>' \
-H 'authorization: token <greptime_user:greptimedb_password>' \
-d 'census,location=klamath,scientist=anderson bees=23 1566086400000000000'
Expand All @@ -26,7 +26,7 @@ curl -X POST 'https://<host>/v1/influxdb/api/v2/write?bucket=<db-name>' \

<TabItem value="InfluxDB line protocol v1" label="InfluxDB line protocol v1">

```shell
```shell
curl 'https://<host>/v1/influxdb/write?db=<db-name>&u=<greptime_user>&p=<greptimedb_password>' \
-d 'census,location=klamath,scientist=anderson bees=23 1566086400000000000'
```
Expand All @@ -44,7 +44,7 @@ curl 'https://<host>/v1/influxdb/write?db=<db-name>&u=<greptime_user>&p=<greptim

<TabItem value="InfluxDB line protocol v2" label="InfluxDB line protocol v2">

```toml
```toml
[[outputs.influxdb_v2]]
urls = ["https://<host>/v1/influxdb"]
token = "<greptime_user>:<greptimedb_password>"
Expand All @@ -57,7 +57,7 @@ curl 'https://<host>/v1/influxdb/write?db=<db-name>&u=<greptime_user>&p=<greptim

<TabItem value="InfluxDB line protocol v1" label="InfluxDB line protocol v1">

```toml
```toml
[[outputs.influxdb]]
urls = ["https://<host>/v1/influxdb"]
database = "<db-name>"
Expand All @@ -77,7 +77,7 @@ curl 'https://<host>/v1/influxdb/write?db=<db-name>&u=<greptime_user>&p=<greptim

<TabItem value="Node.js" label="Node.js">

```js
```js
'use strict'
/** @module write
**/
Expand Down
4 changes: 2 additions & 2 deletions docs/reference/sql/cast.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ CAST (expression AS data_type)

Convert a string to an integer:

```sql
```sql
SELECT CAST('123' AS INT) ;
```
```

```sql
+-------------+
Expand Down
56 changes: 28 additions & 28 deletions docs/user-guide/cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ You can follow the steps to use SQL to play with distributed insertions and quer

1. Use MySQL cli to connect to Frontend.

```shell
```shell
mysql -h 127.0.0.1 -P 4002
```
```

2. Create a distributed table via `CREATE` statement.

```SQL
```SQL
CREATE TABLE dist_table(
ts TIMESTAMP DEFAULT current_timestamp(),
n INT,
Expand All @@ -32,11 +32,11 @@ You can follow the steps to use SQL to play with distributed insertions and quer
n >= 9
)
engine=mito;
```
```

The result looks like the following:

```shell
```shell
mysql> CREATE TABLE dist_table(
-> ts TIMESTAMP DEFAULT current_timestamp(),
-> n INT,
Expand All @@ -51,13 +51,13 @@ You can follow the steps to use SQL to play with distributed insertions and quer
-> )
-> engine=mito;
Query OK, 3 rows affected (0.09 sec)
```
```

The `dist_table` is distributed among the `Datanode`s. You can refer to ["Table Sharding"](/contributor-guide/frontend/table-sharding.md) for more details.

3. Insert some data via `INSERT` statement.

```SQL
```SQL
INSERT INTO dist_table(n, row_id) VALUES (1, 1);
INSERT INTO dist_table(n, row_id) VALUES (2, 2);
INSERT INTO dist_table(n, row_id) VALUES (3, 3);
Expand All @@ -70,15 +70,15 @@ You can follow the steps to use SQL to play with distributed insertions and quer
INSERT INTO dist_table(n, row_id) VALUES (10, 10);
INSERT INTO dist_table(n, row_id) VALUES (11, 11);
INSERT INTO dist_table(n, row_id) VALUES (12, 12);
```
```

4. Execute some queries via `SELECT` statement:

```sql
```sql
SELECT * FROM dist_table ORDER BY n LIMIT 5;
```
```

```sql
```sql
+---------------------+------+--------+
| ts | n | row_id |
+---------------------+------+--------+
Expand All @@ -89,39 +89,39 @@ You can follow the steps to use SQL to play with distributed insertions and quer
| 2022-11-14 12:02:32 | 5 | 5 |
+---------------------+------+--------+
5 rows in set (0.081 sec)
```
```

```sql
```sql
SELECT MAX(n) FROM dist_table;
```
```

```sql
```sql
+-------------------+
| MAX(dist_table.n) |
+-------------------+
| 12 |
+-------------------+
1 row in set (0.057 sec)
```
```

```sql
```sql
SELECT MIN(n) FROM dist_table;
```
```

```sql
```sql
+-------------------+
| MIN(dist_table.n) |
+-------------------+
| 1 |
+-------------------+
1 row in set (0.079 sec)
```
```

```sql
```sql
SELECT * FROM dist_table WHERE n > 2 AND n < 10 ORDER BY row_id;
```
```

```sql
```sql
+---------------------+------+--------+
| ts | n | row_id |
+---------------------+------+--------+
Expand All @@ -134,17 +134,17 @@ You can follow the steps to use SQL to play with distributed insertions and quer
| 2022-11-14 12:02:32 | 9 | 9 |
+---------------------+------+--------+
7 rows in set (0.02 sec)
```
```

```sql
```sql
SELECT * FROM dist_table WHERE row_id = 10;
```
```

```sql
```sql
+---------------------+------+--------+
| ts | n | row_id |
+---------------------+------+--------+
| 2022-11-14 12:02:32 | 10 | 10 |
+---------------------+------+--------+
1 row in set (0.03 sec)
```
```
31 changes: 31 additions & 0 deletions docs/user-guide/ingest-data/for-iot/grpc-sdks/template.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,4 +94,35 @@ Streaming insert is useful when you want to insert a large amount of data such a

<InjectContent id="ingester-lib-reference" content={props.children}/>

<!-- ## Query data

GreptimeDB uses SQL as the main query language and is compatible with MySQL and PostgreSQL.
Therefore, we recommend using mature SQL drivers to query data.

### Recommended library

<InjectContent id="recommended-query-library" content={props.children}/>

### Installation

<InjectContent id="query-library-installation" content={props.children}/>

### Connect to database

The following example shows how to connect to GreptimeDB:

<InjectContent id="query-library-connect" content={props.children}/>

### Raw SQL

We recommend you using raw SQL to experience the full features of GreptimeDB.
The following example shows how to use raw SQL to query data.

<InjectContent id="query-library-raw-sql" content={props.children}/>

### Query library reference

For more information about how to use the query library, please see the documentation of the corresponding library:

<InjectContent id="query-lib-doc-link" content={props.children}/> -->

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ greptime/greptimedb:VAR::greptimedbVersion standalone start \

1. 设置 `--security-opt seccomp=unconfined`:

```shell
```shell
docker run --security-opt seccomp=unconfined -p 4000-4003:4000-4003 \
-v "$(pwd)/greptimedb:/tmp/greptimedb" \
--name greptime --rm \
Expand All @@ -77,7 +77,7 @@ greptime/greptimedb:VAR::greptimedbVersion standalone start \
--rpc-addr 0.0.0.0:4001 \
--mysql-addr 0.0.0.0:4002 \
--postgres-addr 0.0.0.0:4003
```
```

2. 将 Docker 版本升级到 v23.0.0 或更高;
:::
Expand Down

This file was deleted.

Loading
Loading