Information Management: Prof. Sara Foresti, Prof. Giovanni Livraga

You might also like

You are on page 1of 2

Information Management

Prof. Sara Foresti, Prof. Giovanni Livraga


January 25, 2022
Time available 2:00 hours (1:30 hours for students who do not answer to Q5)

Question 1)

1. Illustrate the concept of happened before characterizing logical clocks.


2. Illustrate the working of Lamport clocks and of Vector clocks.
3. Considering the attached schema, indicate the timestamp associated with each operation of each process. For the exercise,
assume to adopt Lamport clocks and that all the timestamps are initialized to 0. Operations are denoted with a tick on the
line of the corresponding process.
To answer the question, indicate in the order the values of the vector clock associated with each operation for each
process:
P1 : lc1 , lc2 ,. . .
P2 : lc1 , lc2 ,. . .
P3 : lc1 , lc2 ,. . .
Question 2)
1. Illustrate the concept of fact, dimension, and measure, providing an example.
2. Describe the star and snowflake schemas for data warehouses, illustrating their differences.
3. Considering relation T

T
product color location quantity
t-shirt red Milan 100
t-shirt blue Milan 150
t-shirt red Florence 70
t-shirt white Florence 50
pants blue Milan 200
pants blue Florence 80
pants white Milan 20
pants white Florence 30

write the three SQL queries operating on T that would generate the following three relations.
Query 1 Query 2 Query 3
product color quantity product color location quantity product color location quantity
t-shirt red 100 t-shirt red Milan 100 t-shirt ALL ALL 370
t-shirt blue 150 t-shirt blue Milan 150 pants ALL ALL 330
pants blue 200 t-shirt red Florence 70 ALL red ALL 170
pants white 20 pants blue Milan 200 ALL blue ALL 430
t-shirt ALL 250 pants blue Florence 80 ALL white ALL 50
pants ALL 220 t-shirt red ALL 170
ALL red 100 t-shirt blue ALL 150
ALL blue 350 pants blue ALL 280
ALL white 20 t-shirt ALL ALL 320
ALL ALL 470 pants ALL ALL 280
ALL ALL ALL 600

Question 3)
1. Describe and discuss the association rule mining and the frequent itemset mining problems.
2. Illustrate the relationship between these two problems.
3. Illustrate the working of FP-trees for solving the frequent itemset mining problem.
4. Considering the table below and assuming min sup=0.75, identify all the frequent itemsets using FP-trees.
TID Items
1 B, D, C, A
2 B, A, E
3 A, D, B, E
4 C, D, A

Question 4)
Illustrate the main differences between relational and NoSQL databases.

Question 5) only for students who did not attend database course with Prof. Samarati
1. Briefly illustrate ACID properties.
2. Given the following log:

DUMP, B(T1), B(T2), U(T1,O1,B1,A1), I(T2,O2,A2), B(T3), D(T1,O3,B3), A(T1), B(T4), CK(. . . ), U(T3,O4,B4,A4),
D(T4,O5,B5), I(T3,O6,A6), B(T5), I(T5,O7,A7), C(T3), B(T6), D(T6,O8,B8), C(T4), A(T2), U(T5,O9,B9,A9) FAILURE
(a) write, for each checkpoint record, active transactions;
(b) illustrate in the details the steps of a warm restart to recover from failure.

You might also like