Great Deal! Get Instant $10 FREE in Account on First Order + 10% Cashback on Every Order Order Now

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 »
XXXXXXXXXXFor each situation presented below, illustrate a document as depicted in Figures 10-4 and 10-5 and specify whether it contains an a
ay, an embedded subdocument, relationships, or collections. Use hypothetical data and make necessary assumptions.
a. A document containing Book details: Title, Publisher, Year, and Edition.
. 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 a
ay?
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 Day May 27, 2021

Solution

Shivani answered on May 29 2021
157 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 a
ay, 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: A
ay of attributes
3. year: Intege
4. edition: A
ay of attributes
. 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