2.9.2 SODA
SODA allows schemaless application development using the JSON data model. The options are:
-
SODA create <collection_name>
— Create a new collection -
SODA list
— List all the collections -
SODA get <collection_name> [-all | -f | -k | -klist] [{<key> | <k1> <k2> ... | <qbe>}]
— List documents the collection. Optional arguments:-
all
: list the keys of all docs in the collection -
k
: list docs matching the specific <key> -
klist
: list docs matching the list of keys -
f
: list docs matching the <qbe>
-
-
SODA insert <collection_name> <json_str | filename>
— Insert a new document within a collection -
SODA drop <collection_name>
— Delete existing collection -
SODA count <collection_name> [<qbe>]
— Count number of documents inside collection. Optional parameter<qbe>
returns number of matching documents -
SODA replace <collection_name> <oldkey> <new_{str | doc}>
— Replace one document with another -
SODA remove <collection_name> [-k | -klist | -f] {<key> | <k1> <k2> ...| <qbe>}
— Remove documents from collection. Optional arguments:-
k
: Remove document in collection matching the specific <key> -
klist
: Remove document in collection matching the list <key1> <key2> ... -
f
: Remove document in collection matching <qbe>
-