Escrito por estudiantes que aprobaron Inmediatamente disponible después del pago Leer en línea o como PDF ¿Documento equivocado? Cámbialo gratis 4,6 TrustPilot
logo-home
Document preview thumbnail
Vista previa 2 fuera de 12 páginas
Examen

DBMS EXAM 3 QUESTIONS AND ANSWERS

Document preview thumbnail
Vista previa 2 fuera de 12 páginas

DBMS EXAM 3 QUESTIONS AND ANSWERS

Vista previa del contenido

DBMS EXAM 3 QUESTIONS AND
ANSWERS


Write a filter to return all documents where the listed property type is Chalet and the
chalet has at least 1 bedroom. - Correct Answers -{property_type: "Chalet", bedrooms:
{$gte: 1}}

Write a filter that returns all documents that are located in Turkey and where the host is
classified as a superhost. - Correct Answers -{"host.host_is_superhost": true,
"address.country": "Turkey"}

Write a filter to return all documents where the property type is Apartment and that have
exactly 5 amenities. - Correct Answers -{property_type: "Apartment", amenities: {$size:
5}}

Write a filter to return all documents that can accommodate exactly 2 people. - Correct
Answers -{accommodates: 2}

Write a filter to return all documents where the cancellation policy is "moderate" and the
price is less than $50. - Correct Answers -{cancellation_policy: "moderate", price: {$lt:
50}}

Write a filter to return all documents where the amenities contain "TV" and "Wifi". -
Correct Answers -{amenities: {$all: ["TV", "Wifi"]}}

Write a filter to return all documents where the number of bedrooms is not provided (null
or undefined). - Correct Answers -{"bedrooms": null}

Write a filter to return all documents where the host location is "Montreal, Quebec,
Canada" and the host has been verified via a "government_id" and a "phone". - Correct
Answers -{"host.host_location": "Montreal, Quebec, Canada",
"host.host_verifications": {$all: ["government_id", "phone"]}}

Write a filter to return all documents where the property type is Serviced apartment and
have a cleanliness review score > 9. - Correct Answers -{"property_type": "Serviced
apartment",
"review_scores.review_scores_cleanliness": {$gt: 9}}

Write a filter to return all documents where cancellation policy is "flexible" or
"super_strict_60" and picture urls for images are provided. - Correct Answers -
{cancellation_policy: {$in: ["flexible", "super_strict_60"]}, "images.picture_url": {$exists:
true, $ne: ""}}

, Write a filter to return all documents mentioning the word "clean" in the reviews and
having a review score cleanliness greater than 9. - Correct Answers -{reviews:
{$elemMatch: {comments: {$regex: 'clean'}}},
"review_scores.review_scores_cleanliness": {$gt: 9}}

Write a filter to return all documents with property type "Resort" that have all of the
following amenities: "Wifi", "Hot tub", "Wheelchair accessible". - Correct Answers -
{property_type: "Resort", amenities: {$all: ["Wifi", "Hot tub", "Wheelchair accessible"]}}

Write a filter to return all documents where the host name is "Ali", and the identity is
verified.(host_identity_verified) - Correct Answers -{"host.host_name": "Ali",
"host.host_identity_verified": true}

Write a filter to return all documents where the first amenity listed is "Wifi". - Correct
Answers -{"amenities.0": "Wifi"}

Write a filter to return all documents where one of the amenities begins with the letter
'H". - Correct Answers -{amenities: {$elemMatch: {$regex: "(?i)^H"}}}

Write a filter that returns all documents that have a market equal to: "Hong Kong", "New
York", "Porto", "Sydney" or "Istanbul" in the address field. - Correct Answers -
{"address.market": {$in: ["Hong Kong", "New York", "Porto", "Sydney", "Istanbul"]}}

Find all documents where genre is Drama - Correct Answers -{genres: "Drama"}

Find all movies where genre is Drama - Correct Answers -{genres: "Drama", type:
"movie"}

Find all movies where the genre is Drama or History - Correct Answers -{$or: [{genres:
"Drama}, {genres: "History"}]}

Find all movies where the genre is Drama and History - Correct Answers -{genres: {$all:
{"Drama", "History"]} type: "movie"}

Find movies with 2 genres - Correct Answers -{genres: {$size:2}}

Find all documents where the imdb.id is between 20000 and 40000 - Correct Answers -
{'imdb.id': {$gte: 20000, $lte: 40000}}

What is the hierarchy of MongoDB? - Correct Answers -Instace has databases has
collections has documents has fields and attributes

MongoDB doesn't have a (DDL / DML); why? - Correct Answers -DDL; each object has
its own structure, so no need for data definition language

Información del documento

Subido en
10 de febrero de 2026
Número de páginas
12
Escrito en
2025/2026
Tipo
Examen
Contiene
Preguntas y respuestas
$13.49

¿Documento equivocado? Cámbialo gratis Dentro de los 14 días posteriores a la compra y antes de descargarlo, puedes elegir otro documento. Puedes gastar el importe de nuevo.
Escrito por estudiantes que aprobaron
Inmediatamente disponible después del pago
Leer en línea o como PDF

Seller avatar
Los indicadores de reputación están sujetos a la cantidad de artículos vendidos por una tarifa y las reseñas que ha recibido por esos documentos. Hay tres niveles: Bronce, Plata y Oro. Cuanto mayor reputación, más podrás confiar en la calidad del trabajo del vendedor.
millyphilip
3.6
(555)
Vendido
2958
Seguidores
1963
Artículos
45809
Última venta
2 días hace


Por qué los estudiantes eligen Stuvia

Creado por compañeros estudiantes, verificado por reseñas

Calidad en la que puedes confiar: escrito por estudiantes que aprobaron y evaluado por otros que han usado estos resúmenes.

¿No estás satisfecho? Elige otro documento

¡No te preocupes! Puedes elegir directamente otro documento que se ajuste mejor a lo que buscas.

Paga como quieras, empieza a estudiar al instante

Sin suscripción, sin compromisos. Paga como estés acostumbrado con tarjeta de crédito y descarga tu documento PDF inmediatamente.

Student with book image

“Comprado, descargado y aprobado. Así de fácil puede ser.”

Alisha Student

Preguntas frecuentes