Tags: replace PAT document database rules SIG signed logical Environment installation build table Mongodb+mongovue installation and Getting StartedTransfer from CSDN
Preface and Concept
Environment installation
The installation of MongoDB
Mongovue Installation
Establish a connection
Basic operations
Mongovue is a client-side tool for MongoDB, now connected to the database is also called Data Schema 2 methods, one is B/s structure of the database, through the Web page can be accessed. The other is based on C/S Client connection mode, this time for you to share this tool is a client-side tool of type C/S.Method/Step
1 Download installation Mongovue, install finish click the Desktop
databaseDb.dropdatabase ()Help for 10.ShellThere are all the commands that the shell can do to helpGlobal Help database related to the DB.HELP () collection-related db. [Documentname].help ()API for 11.mongoDBhttp://api.mongodb.org/js/Database and collection naming conventions
Should all lowercase
Maximum of 64 bytes
The database name cannot have the same name as the existing system reserved library, such as admin,local, and config
Such collection names are also legal, but
Recently the project used to MongoDB, then installed a Mongovue, of course, is cracked version.But there is a small problem, that is, table view view the following title text label is missing, the Execute button of find is also blank piece:began to think that cracked not thorough, re-installed again, found that the problem is still.And then online to find a big circle, occasionally see a similar content, said to be set under the system font to the def
I have been in the terminal operation of the MONGO, various update set remove INSERT, and then looked under a mongovue called the client, the interface is more convenient to operate it ~Online search, said Mongovue has been n years has not been updated.However, it is still recorded, because its configuration is somewhat interesting.A moment to downloadOfficial website: http://www.mongovue.com/downloads/Two-
I am used to the use of the mysql graphical interface. It is always inconvenient to use mongo to view the command line. The dedicated vue is a good choice!
Installation cracking:(Partially transferred from: http://blog.csdn.net/hengyunabc/article/details/7276376)
MongoVUE is a useful MongoDB client. However, the free version cannot use gridfs, Server Monitoring, and other functions 15 days later.
Using the Process Monitor tool to Monitor the regist
;//Run this command to see a collection of system.indexes and System.users twoUse working_collection//into the working databaseDb.adduser (' Test ', ' 123456 ');Show collections;//Run this command and see the system.indexes and System.users two collectionsThis completes the Super Administrator privilege for the entire Mongod and the administrator permissions on a database.If you want to use authorization to access the working database, you need to start the Mongod or MongoDB service using the--a
Used for a period of time, mongovue some of the commonly used in the Mongovue of the query record, in order to consult.1, and queryQuery date equals 2016-01-08, and Page_url equals shouye.html{"Date": "2016-01-08", "Page_url": "Shouye.html"}2, $gte greater than or equal to, $gt greater than, $lte less than or equal to, $gt less thanThe query date is greater than or equal to 2016-01-08 00:00:00, and is less
We know that MongoDB is a kind of relational database, so its query method is very different from the standard Structured Query language SQL. But no matter how complicated a structure it is, when it passes through the developer's hands, it only becomes the structure that the customer wants. Today is about how to MongoDB group group queries under Mongovue.
The Mongovue query format is as follows:
Db.collecti
We know that MongoDB is a non-relational database, so its query method is very different from the standard Structured Query language SQL. But no matter how complex a structure it is, when it passes through the developer's hands, it can only become the structure that the customer wants. Today is to tell the Mongovue how to MongoDB group Group query.
The query format for Mongovue is as follows:
Db.collection.
Yesterday there was a system problem, resulting in a large number of bad data in the middle of the night, early in the morning to receive the above notice to delete the data.Admittedly, Mongovue is more intuitive in data manipulation, so I use this tool in general, but today there are problems.First I queried the amount of data to be deleted, the query operation is normal,Then the same conditions are performed to delete the remove operation, and the r
First, the questionAfter installing the 3.4 mongdb, I randomly downloaded a Mongovue client online, unable to view the default database local collection, and the following issue occurred when creating the collection
Error in creating new CollectionObject references are not set to an instance of an object.Type:System.NullReferenceExceptionStack: In MangoUI.ComNavTree.dbAddCollection_Click (Object sender, EventArgs e)After searching on the internet, so
The connection Mongovue is not connected to the problem:Connection was refusedUnable to connect to server localhost:27017: Object reference not set to an instance of an object ...Type:MongoDB.Driver.MongoConnectionExceptionStack: At MongoDB.Driver.Internal.DirectMongoServerProxy.Connect (TimeSpan timeout, readpreference readpreference)Workaround:Just the following three lines do not enter anything. This test can be successfully connected directly.Use
Specify the database path
--port
Specifying the service port number, default port 27017
--servicename
Specify the service name
--servicedisplaynam
Specifies the service name that is executed when there are multiple MongoDB services.
--install
Specifies the installation as a Windows service.
The specific installation method is this ~---------------------------------------------------------------------------
First, train of thoughtMongovue free version support MySQL import MONGO, so the idea is that SQL Server import MySQL, and then import MONGO from MySQL.
Second, prepare
1, install MySQL database (I am using Wamp, integrated mysql,phpadmin), if necessary, build your own database such as MyData
2, download Mysql-connector-odbc-5.1.12-win32.msi, install
3, Start---> admin tools---> Data source (ODBC)---> User DSN, add MySQL ODBC 5.1 Driver
4, in SQL Server object, linked server, right key new
Step 1Open Mongovue and connect to the server that contains the collection "Cities"Step 2Right-click on "Cities" collection under "Database Explorer", and select "MapReduce". This would launch the MapReduce view.Step 3Write the JavaScript code for MAP function in "Map" tab.Step 4Go to "Reduce" tab and enter your JavaScript Reduce code.Step 5Go to "Finalize" tab and enter your JavaScript Finalize code.Step 6Go to ' in Out ' tab. Enter the Json code un
which to set the sort method;The format of the sort area is: {"id": 1} or {"id": -1},1 is sorted by ID in ascending order,-1 means sort by id descending. The Limit is used to set how many records are returned, andskip is used to set how many records to skip.Third, deleteSelect the collection to be manipulated, click Remove to go to the delete panel, enter the query criteria to delete the data, click Remove, and confirm the deletion in the pop-up prompt box.Iv. modificationSelect the collection
Mongovue is a more useful MongoDB client, need to register, but can become permanent use, one, the basic operation
Add a connection
Enter the interface shape as
second, advanced Operation
1, see all the data, there will be three forms of viewing mode, respectively, tree, table, BJOSN, details see 1.1
2, to view the specific data, the use of the shell command, need some basic knowledge of grammar, details see 2.1
3. Update the data, see 3.1 for de
1. Assume that the following records are available:{"_id": ObjectId ("51d7b0d436332e1a5f7299d6"), "name": {"First": "Barack", "Last": "Obama"}}To find out that first barack,last was the Obama record.Precise representation of the key of an inline
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.