The following table is a few of the data types commonly used in MongoDB.
Data Type
Description
String
String. Data types commonly used to store data. In MongoDB, the UTF-8 encoded string is legal.
MongoDB Create Collection1. Manually Create:Syntax format:DB. CreateCollection(name, options) Parameter description:
Name: The collection name to create
Options: Optional parameters, specifying option for memory size and index
A summary of MongoDB knowledge points1.ObjectId 12 bit 4 time stamp +3 machine identification +2 process id+3 random numberGettimestamp ()STR ()2.Map Reduce performs a large amount of work decomposition and then merges the results into the final
The difference between the MongoDB save () method and the Insert () method first look at what the official documents say
Updates an existing document or inserts a new document, depending on its document parameter
The Save method has
MongoDB Download MongoDB offers pre-compiled binary packages for 32-bit and 64-bit systems that you can download from the MongoDB website,MongoDB Pre-compiled binary package: https://www.mongodb.com/download-center#communityCreate data Directory
Insert data:MongoDB uses the Insertone function to insert a single piece of dataSuch as:1. First specify the inserted data with document:Document = ({"Type": "Book", "Title": "Definitive Guide to MongoDB 3rd ed.", "ISBN": "978-1-4842-1183-0",
On the left is the MONGODB query statement, and the right is the SQL statement. Compared with the use, very convenient.
Db.users.find () SELECT * from Users
Db.users.find ({"age": + }) select * from the users where age =
Db.users.find
Before looking at Windows install MongoDB operation is very simple, today in your own notebook installed, a variety of small problems. Refer to the online great god posts, and then record the next simple process to remember later.1.MongoDB official
1.mongodb is document-based (BSON, JSON-like key-value pairs to store), not table-based, easy to scale horizontally, the internal related data can be put together to improve the operational performance of the database. If you want to create a new
This refers to the MongoDB driver of PHP.Version:> Cat/etc/os-releaseName= "CentOS Linux"version= "7 (Core)"Id= "CentOS"Id_like= "Rhel Fedora"Version_id= "7"Pretty_name= "CentOS Linux 7 (Core)"Ansi_color= "0;31"Cpe_name= "Cpe:/o:centos:centos:7"Home_
1.NoSQL Introduction
NoSQL, full name not only SQL, refers to a non-relational database
With the increase in traffic, there is a problem with the database performance of the website, so NoSQL is designed
Advantages and
Before the start of MongoDB is normal, do not know the start error later, the paste out query. Finally know is due to their abnormal shutdown caused by this situation.--Excerpt: MongoDB abnormal shutdown after repair recordMongod no background
Basic operation of MongoDBEnter MONGO into the database in CMD. Enter show databases can query the existing database, admin and local are the own database, notTo operate these two databases. The following is the basic operation of MongoDB: additions
Document Query
Command
Operation
db.mycoll.find(key:value)
Data for query condition
db.mycoll.find(...).count()
Querying and Counting
db.mycoll.find(...).limit(n)
Two days ago in learning MongoDB related knowledge, did a small demo, do is the province below how many schools, well, do more rough ...Connect MongoDB first to add a MongoDB package through NuGet, download this packageStart writing code after
MongoDB Concept Analysis:Database tables that are equivalent to SQL: CollectionDocument: Data record lines that are equivalent to SQLField: Data field equivalent to SQLTable connection, MongoDB not supportedPrimary key, MongoDB automatically sets
Query data using DB. Table name. Find () query data If you do not specify a condition, the default query is all for example > Db.noPK.find () {"_id": ObjectId ("5a50642b908e6b07a84472a2"), " Name ":" JavaScript "," Value ":" Vue.js "} {" _id ":
Reference Link: http://www.runoob.com/mongodb/mongodb-tutorial.htmlOschina Link: https://gitee.com/dhclly/icedog.script.test/tree/devp-work/momgodb/v2.4.9
Quickly open a MongoDB console instanceFirst go to the bin directory that contains the
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service