XXXXXXXXXXFor each situation presented below, illustrate a document as depicted in Figures 10-4 and 10-5 and specify whether it contains an array, an embedded subdocument, relationships, or...

1 answer below »
Please answer the 3 questions in the document.


10-24. For each situation presented below, illustrate a document as depicted in Figures 10-4 and 10-5 and specify whether it contains an array, an embedded subdocument, relationships, or collections. Use hypothetical data and make necessary assumptions. a. A document containing Book details: Title, Publisher, Year, and Edition. b. Add Author name: First name and Last name to the document and specify the type of document. c. Now add “SalesRegion”, which has the subfields “Region” and “RCode”, and we can take values of “NorthEast”, “SouthWest”, “SouthEast”, and “01”, “02”, “03,” respectively. Is this an array? d. Assume that each book is reviewed by many Reviewers. Reviewer details-ID, Name (First and Last), Experience- are in a separate document. Present this relationship in a document. 10-25. Write two HIVE queries, the both to create a PRODUCT table with fields ProdID, Name, Seller, Price. Make all necessary assumptions. Exercise 2:
Answered Same DayMay 27, 2021

Answer To: XXXXXXXXXXFor each situation presented below, illustrate a document as depicted in Figures 10-4 and...

Shivani answered on May 29 2021
163 Votes
10-24. For each situation presented below, illustrate a document as depicted in Figures 10-4 and 10-5 and specify whether it contains an array, an embedded subdocument, relationships, or collections. Use hypothetical data and make necessary assumptions.
a. A document containing Book details: Title, Publisher, Year, and Edition.
{
    "_id":ObjectId(“1”),     // Identifier for the document
    title: “Mastering PL/SQL Quick”,
    publisher: {
         name: "O Reilly Media",
         founded: 1980,
         location: "CA"
         }
    year: 1992,
    edition: {
         edition_no: 1,
         ISBN: 9781565129238,
         edition_type: "First Edition"
         }
}
The above MongoDB document records details of a book. The datatypes of it’s attributes are as below:
1. Title: String
2. publisher: Array of attributes
3. year: Integer
4. edition: Array of attributes
b. Add Author name: First name and Last name to the document and specify the type of document.
{
    "_id": ObjectId(“1”),     // Identifier for the document
    title: “Mastering PL/SQL Quick”,
    publisher: {
         name: "O Reilly Media",
         founded: 1980,
         location: "CA"
         }
    year: 1992,
    edition: {
         edition_no: 1,
         ISBN: 9781565129238,
         edition_type: "First Edition"
         },
author: {
...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here