• Non ci sono risultati.

Design - Part A

N/A
N/A
Protected

Academic year: 2021

Condividi "Design - Part A"

Copied!
1
0
0

Testo completo

(1)

Design - Part A

1. The following relations are given (primary keys are underlined):

TOURIST(TouristID, Name, BirthDate, CreditCard, Nation) RESORT(ResortCode, CompanyName, Name, City, #Stars) AVAILABLE SERVICES(ResortCode, CompanyName, ServiceName)

RESERVATION STAY(TouristID, StayStartDate, ResortCode, CompanyName StayEndDate, Amount, #Adults, #Children, DownPayment)

Write the following queries

(a) Mandatory exercise in algebra (4 points):

Find the code and the name of the tourists who have only ever reserved stays at resorts equipped with free wi-fi (ServiceName=’free wifi’).

(b) Mandatory exercise in SQL language (5 points):

For each tourist born after 1980 who has made at least 3 reservations for the same resort, find the tourist name and country, the total number of reservations made by the tourist, the total number of adults for which reservations have been made and the corresponding total amount.

(c) Optional exercise in SQL language (5 points):

Find the resort code and company name of the 4-star resorts which (i) have never received a reservation whose down payment is equal to the amount, and (ii) have received more reservations from Italian tourists than from German ones.

1

Riferimenti

Documenti correlati

It might be true that changing the scope of science communication - from mere knowledge transfer to public debate on science and technology to public participation in the

This paper presents a potential lesson to advanced learners of English designed to help them make critical reflections upon why, within a European context

australis leaves varied significantly among seasons in both lentic ecosystems, Alimini Grande and Alimini Piccolo (one-way ANOVA, P<0.001), while in the lotic ecosystem, reed

Then we have studied the abundance gradients along the Galactic disk produced by our best cosmological model and their dependence upon several parameters: a threshold in the surface

T.officinalis and R. However, we did not find any reference on the effect of air drying on volatile composition of these two species cultivated in Sardinia. Consequently, the aim

In 2006, The American College of Medical Genetics (ACMG), a group made up of specialists in public health, health policy, ethics, and other sectors involved in neonatal

2D computational model domain and boundary conditions: (a) geometry of the 2D longitudinal central section: the gas and PFC half-channels used as computational domain are

The authors analyzed the expression variations of adipokines (leptin, adiponectin, and visfatin) with lipolysis-related proteins in the white adipose tissue of cachectic cancer