7/31/2023 0 Comments Robo 3t search commands![]() ![]() That said, the table and tree views do offer the ability to select a single document and view or edit the JSON of that document in a separate editor window. The various views have their advantages and disadvantages some prefer the JSON/text document view as its the native MongoDB format and the table and tree views can exhibit performance issues. If you want to focus on one result set, at the top right of the results is a maximize/minimize view button. The more result sets returned by the JavaScript, the more the results area splits. A layout button also appears in the toolbar up top to select between horizontal or vertical split layout of the window pressing F10 toggles it too. Richer viewsīut there’s another treat in store – put two queries into the text area and when you run it, the results area splits into two with independent views of each set of results. The text area, like the console shell, also supports auto-completion and is generally an easier space to hone your MongoDB queries. ![]() ![]() One big advantage over the raw Mongo shell is that Robomongo also allows you to save and load this text area so you can save raw scripts without wrapping them in a function and using the database as a store. Note that if you have not placed parentheses after a function name and hit Command/Control-Enter, Robomongo shows you the JavaScript behind that function. The query is run only when you want it run, by clicking the “play” arrow in the toolbar, typing Command/Control-Enter in the text box or pressing F5. This isn’t just a query window anything you can do in the shell you can do here, including defining JavaScript functions and running them. The query itself is shown above the results in an editable multiline text area – that's where we can expand and refine our queries. The result window also displays how long that result took to get so you can get a feel for performance. Unwieldy scrolling results in a terminal are not a problem with Robomongo. Next to the controls, a pair of text fields allow setting the offset and number of documents to display at a time and arrow buttons which makes it easy to page through the results. By default, the results are rendered in a tree-view but above and to the right of the results are controls to also view as a spreadsheet-style table or as a JSON/text document. Robomongo will open the collections into a tab in the main part of the window and do a db.collection.find() for the first 50 documents in the collection, displaying the results. This is just browsing though to get to the power controls of Robomongo, double click on one of the collections. Clicking through reveals the collections and hovering over the collection names will display a count of documents and the total size. When you are connected, you can drill down through the tree to the databases. Multiple sessions are therefore easy to manage. ![]() You can add as many servers as you like and you can have as many of these connections open at the same time, each one appearing in the left hand side bar of Robomongo, the navigation tree. When you launch Robomongo, you are given the opportunity to connect to a MongoDB server by creating an entry in its list of available connections. As an added bonus, it includes the ability to make secure connections to your MongoDB instances, but before we cover that, lets look at Robomongo’s core features and how they make your shell life more productive. It is a graphical but shell-oriented alternative to the Mongo shell which makes all those problems easier to handle and is available for Windows, Mac OS X and Linux. That’s why the open source Robomongo is such a welcome addition to the MongoDB tools arsenal. Robomongo: Your Next Shell mongodb Free 30 Day TrialĪlthough powerful, the Mongo shell does suffer from being a strictly console centric experience – multiple sessions require multiple terminals, results scroll away, repetitive commands or honing a function require command line history traversal and so on. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |