Skip to content

Commit 61be4a2

Browse files
author
jensonjing
committed
docs: Update OpenTenBase installation guide
1 parent a60b819 commit 61be4a2

File tree

2 files changed

+36
-2
lines changed

2 files changed

+36
-2
lines changed

docs/guide/01-quickstart.en.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,24 @@ PSQL connection: psql -h 172.16.16.49 -p 11000 -U opentenbase postgres
304304
export LD_LIBRARY_PATH=/home/opentenbase/install/opentenbase/5.21.8/lib && export PATH=/home/opentenbase/install/opentenbase/5.21.8/bin:${PATH}
305305
$ psql -h ${CoordinateNode_IP} -p ${CoordinateNode_PORT} -U opentenbase -d postgres
306306
307-
postgres=#
307+
postgres=# create database test;
308+
CREATE DATABASE
309+
postgres=# create user test with password 'test';
310+
CREATE ROLE
311+
postgres=# alter database test owner to test;
312+
ALTER DATABASE
313+
postgres=# \c test test
314+
You are now connected to database "test" as user "test".
315+
test=> create table foo(id bigint, str text) distribute by shard(id);
316+
CREATE TABLE
317+
test=> insert into foo values(1, 'tencent'), (2, 'shenzhen');
318+
COPY 2
319+
test=> select * from foo;
320+
id | str
321+
----+----------
322+
1 | tencent
323+
2 | shenzhen
324+
(2 rows)
308325
309326
```
310327

docs/guide/01-quickstart.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,24 @@ PSQL connection: psql -h 172.16.16.49 -p 11000 -U opentenbase postgres
301301
export LD_LIBRARY_PATH=/home/opentenbase/install/opentenbase/5.21.8/lib && export PATH=/home/opentenbase/install/opentenbase/5.21.8/bin:${PATH}
302302
$ psql -h ${CoordinateNode_IP} -p ${CoordinateNode_PORT} -U opentenbase -d postgres
303303
304-
postgres=#
304+
postgres=# create database test;
305+
CREATE DATABASE
306+
postgres=# create user test with password 'test';
307+
CREATE ROLE
308+
postgres=# alter database test owner to test;
309+
ALTER DATABASE
310+
postgres=# \c test test
311+
You are now connected to database "test" as user "test".
312+
test=> create table foo(id bigint, str text) distribute by shard(id);
313+
CREATE TABLE
314+
test=> insert into foo values(1, 'tencent'), (2, 'shenzhen');
315+
COPY 2
316+
test=> select * from foo;
317+
id | str
318+
----+----------
319+
1 | tencent
320+
2 | shenzhen
321+
(2 rows)
305322
306323
```
307324

0 commit comments

Comments
 (0)