简体   繁体   中英

Normalisation in NoSQL in Mongo DB

The first table is for products, how would I normalize this data.

  • asin - ID of the product, eg 1574571931
  • categories - list of categories the product belongs to
  • description – description of product
  • title - name of the product
  • brand – brand name of the product

IMAT3104 Database Management and Programming Assignment 2017-18 De Montfort University 2018 Page 6 of 11

  • price - price in US dollars (at time of crawl)
  • salesRank - sales rank information. The better the sales, the lower the rank.
  • imUrl - url of the product image
  • related -

The second table is for reviews and how would I normalize this table as well.

  • reviewerID - ID of the reviewer, eg A2Y113PST5WPPF
  • asin - ID of the product, eg 1574571931
  • reviewerName - name of the reviewer
  • helpful - helpfulness rating of the review, eg 2 out of 3 found review helpful
  • reviewText - text of the review
  • overall - rating of the product
  • summary - summary of the review
  • unixReviewTime - time of the review (unix time in seconds)
  • reviewTime - time of the review (raw)

What is the process of normalization and how can I organize the above 2 tables?

Normalization--a strictly logical process--is the same whether the target platform is a SQL dbms, a large scale C++ program, or a nosql database.

Following the normalization procedures in any good, college-level textbook, normalize every relation to 5NF. Then translate the results to your target platform. (You'll often have to translate declarative code to procedural code.)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM