Skip to content

Commit 8e2ae71

Browse files
committed
Add commands to README
1 parent c52cc6d commit 8e2ae71

File tree

1 file changed

+26
-1
lines changed

1 file changed

+26
-1
lines changed

README.md

+26-1
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,38 @@
33

44
# RedisJSON
55

6+
## Usage
7+
8+
JSON.INDEX ADD <index> <field> <path>
9+
JSON.INDEX DEL <index> <field>
10+
JSON.INDEX INFO <index> <field>
11+
12+
JSON.QGET <index> <query> <path>
13+
JSON.QSET <index> <query> <path> <json> [NX | XX]
14+
JSON.QDEL <index> <query> <path>
15+
16+
Return value from JSON.QGET is an array of keys and values:
17+
18+
key
19+
json
20+
key
21+
json
22+
23+
In a language such as Java this could be represented as a `Map<String, Document>`.
24+
25+
A query combining multiple paths:
26+
27+
JSON.QGET mytype "@path1:hello @path2:world" d.name
28+
629

730
## Build
31+
832
```bash
933
cargo build --release
1034
```
1135

1236
## Run
37+
1338
```
14-
redis-server --loadmodule ./target/release/libredisjson.so
39+
redis-server --loadmodule ./target/release/libredisjson.so
1540
```

0 commit comments

Comments
 (0)