ArangoDB Shell Output
By default, the ArangoDB shell uses a pretty printer when JSON documents are printed. This ensures documents are printed in a human-readable way:
arangosh> db._create("five")
[ArangoCollection 30076, "five" (type document, status loaded)]
arangosh> for (i = 0; i < 5; i++) db.five.save({value:i})
arangosh> db.five.toArray()
[
{
"_key" : "30086",
"_id" : "five/30086",
"_rev" : "_V3azP5q--A",
"value" : 2
},
{
"_key" : "30092",
"_id" : "five/30092",
"_rev" : "_V3azP5u--_",
"value" : 4
},
{
"_key" : "30079",
"_id" : "five/30079",
"_rev" : "_V3azP5q---",
"value" : 0
},
{
"_key" : "30089",
"_id" : "five/30089",
"_rev" : "_V3azP5u---",
"value" : 3
},
{
"_key" : "30083",
"_id" : "five/30083",
"_rev" : "_V3azP5q--_",
"value" : 1
}
]
arangosh> db._create("five")
arangosh> for (i = 0; i < 5; i++) db.five.save({value:i})
arangosh> db.five.toArray()
While the pretty-printer produces nice looking results, it will need a lot of screen space for each document. Sometimes, a more dense output might be better. In this case, the pretty printer can be turned off using the command stop_pretty_print().
To turn on pretty printing again, use the start_pretty_print() command.