Skip to content

Commit 3728a3e

Browse files
authored
update doc (#397)
1 parent 0b48a7c commit 3728a3e

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

docs/1_started.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ pip install nebula5_python==5.2.0
1010
from source
1111

1212
```bash
13-
git clone -b https://github.com/vesoft-inc/nebula-python.git
13+
git clone -b dev https://github.com/vesoft-inc/nebula-python.git
1414
cd nebula-python
1515
pip install -e .
1616
```
@@ -127,6 +127,23 @@ with NebulaClient(
127127

128128
If you prefer manual lifecycle control, you can explicitly open and close clients.
129129

130+
- Sync version:
131+
132+
```python
133+
from nebulagraph_python import NebulaClient
134+
135+
client = NebulaClient(
136+
hosts=["127.0.0.1:9669"],
137+
username="root",
138+
password="NebulaGraph01",
139+
)
140+
try:
141+
result = client.execute("RETURN 1 AS a, 2 AS b")
142+
result.print()
143+
finally:
144+
client.close()
145+
```
146+
130147
- Async version:
131148

132149
```python

0 commit comments

Comments
 (0)