0% found this document useful (0 votes)
16 views

DB1 Exam Info

Database SQL exercices

Uploaded by

Edimarf Satumbo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views

DB1 Exam Info

Database SQL exercices

Uploaded by

Edimarf Satumbo
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Databases I.

Exam

Dear Students,

Here I would like to give you some important information about the exam.
Below is a list of all the exercise types that can occur in the exam.
In the exam you will get only 6 exercises.

1. Relational algebra

• You have to express a query in relational algebra for some sample data and you have to run the
query in relational algebra calculator (see Rel_alg_calculato.txt).
• You have to compute the result of some relational algebra expression in paper, like in
db1_exercise6.pdf (Exercise 3, Exercise 4)
• You have to convert a relational algebra expression into SELECT

2. SQL SELECT

• You have to write an SQL query and run it on some sample data.
• You have to convert a SELECT statement into relational algebra.

3. SQL DML statement

• You have to write an SQL DML statement (INSERT, DELETE, UPDATE) and run it on some
sample data.

4. SQL WITH statement

• You have to write an SQL query using the WITH statement and run it on some sample data.

5. DATALOG

• You have to express a query in Datalog (in paper).


• You have to convert relational algebra into Datalog and vica versa. (see Textbook 5.4.8)

6. Recursion in Datalog and in SQL

• You have to write a recursive query (WITH or CONNECT BY) and run it on some sample data.
• You have to write a recursive Datalog query (in paper).

7. Entity-Relationship models and DDL

• You will get an E-R model, and you have to convert it into relations, and you have to write the
appropriate CREATE TABLE statements with primary key and foreign key definitions.

8. PL/SQL

• You have to write a pl/sql program (function or procedure) and run it on some sample data.
9. Functional Dependencies

• Compute the closure of a set of attributes.


• Decide if a Functional Dependency follows from some other FD’s.
• Find the keys of a relation. (like Exercise 3.2.1)
• Compute a minimal basis for a set of Functional Dependencies.
• Compute the projection of a set of FD’s. (like Exercise 3.2.10)

10. Normal Forms

• Decompose a relation into relations which are in Boyce-Codd Normal Form. (like Exercise 3.3.1)
• Test if a decomposition is a Lossless Join decomposition -> Chase Test. (like Exercise 3.4.1)

You might also like