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 29344, "five" (type document, status loaded)]
arangosh> for (i = 0; i < 5; i++) db.five.save({value:i})
arangosh> db.five.toArray()
[
{
"_key" : "29360",
"_id" : "five/29360",
"_rev" : "_U_D12Fe--_",
"value" : 4
},
{
"_key" : "29357",
"_id" : "five/29357",
"_rev" : "_U_D12Fe---",
"value" : 3
},
{
"_key" : "29351",
"_id" : "five/29351",
"_rev" : "_U_D12Fa---",
"value" : 1
},
{
"_key" : "29354",
"_id" : "five/29354",
"_rev" : "_U_D12Fa--_",
"value" : 2
},
{
"_key" : "29347",
"_id" : "five/29347",
"_rev" : "_U_D12FW---",
"value" : 0
}
]
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.