Couch MapReduce query, CouchMapReduce

Source: Internet
Author: User
Tags couchdb

Couch MapReduce query, CouchMapReduce

1. MapReduce introduces the traditional relational databases. As long as your data is structured, you can perform any type of query. Apache Couch, in contrast, uses MapReduce (a predefined map and reduce method) for queries. This query method is more flexible because it can adapt to various types of document structures and independently calculate and concurrently compute each document index. This method of combining map and reduce is called "View" in CouchDB terminology )". Different from relational databases, Apache Couch does not declare which tables have result sets or rely on data for effective queries. reduce queries perform grouped queries based on the indexes generated by the map method. The Map method is called once when each document is used as a parameter. you can skip the document or submit one or more view rows as key-value pairs. The Map method may not depend on any information outside the document. This dependency allows incremental and parallel generation of the CouchDB view. The CouchDB view is stored in rows and sorted by keys, which ensures query efficiency in thousands of views. When creating a CouchDB map method, the primary goal is to create an index to store keyword-related data. 2. Prepare relevant data to create simple data through visualization.

{
"RED": 20,
"BLUE": 30,
"GREEN": 40
}

Related Article

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.