Z
Z
zizop2012-07-23 16:46:36
MongoDB
zizop, 2012-07-23 16:46:36

What is the name of the command to improve readability in the MongoDB console?

In the MongoDB training, Derik Retrans mentioned a command that improves the appearance of the sample data displayed in the console. But I forgot what she is :-) Nobody remembers by chance?
Yuzaetsya something like this:
db.collection.name.find().thiscommand();

Answer the question

In order to leave comments, you need to log in

2 answer(s)
G
gaelpa, 2012-07-23
@zizop

1 .pretty()
2. still MongoDB

G
gaelpa, 2012-07-23
@gaelpa

Offtopic, but maybe it will be useful to someone:
Pretty-print for MySQL console ("\G" instead of ";"):

mysql> select * from accounts limit 1 \G
*************************** 1. row ***************************
                     id: 410783
                     email: [email protected]
...
                     nick: gaelpa
1 row in set (0.00 sec)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question