Tentamen DATABASTEKNIK - 1DL116, 1MB025

Relevanta dokument
Tentamen DATABASE TECHNOLOGY - 1MB025

Tentamen DATABASTEKNIK - 1DL116, 1MB025

Tentamen DATABASTEKNIK - 1DL116

Tentamen DATABASTEKNIK - 1DL116

Tentamen DATABASTEKNIK - 1DL116, 1MB025

Support Manual HoistLocatel Electronic Locks

1. Compute the following matrix: (2 p) 2. Compute the determinant of the following matrix: (2 p)

Preschool Kindergarten

Materialplanering och styrning på grundnivå. 7,5 högskolepoäng

Module 1: Functions, Limits, Continuity

Final Exam DATABASE TECHNOLOGY - 1DL300

Database course summary

1. Varje bevissteg ska motiveras formellt (informella bevis ger 0 poang)

Isolda Purchase - EDI

Rättningsmall tenta den 25e oktober Uppgift 1. Uppgift 2. se slides

Schenker Privpak AB Telefon VAT Nr. SE Schenker ABs ansvarsbestämmelser, identiska med Box 905 Faxnr Säte: Borås

FÖRBERED UNDERLAG FÖR BEDÖMNING SÅ HÄR

Isometries of the plane

8 < x 1 + x 2 x 3 = 1, x 1 +2x 2 + x 4 = 0, x 1 +2x 3 + x 4 = 2. x 1 2x 12 1A är inverterbar, och bestäm i så fall dess invers.

Module 6: Integrals and applications

Tentamen DATABASTEKNIK - 1DL116, 1MB025, 1DL124

Webbregistrering pa kurs och termin


TDDB 48 Database technology

Svar till tentamen DATABASTEKNIK - 1DL poäng

Lösningar till tentamen i EDAF75

Calculate check digits according to the modulus-11 method

Beijer Electronics AB 2000, MA00336A,

Support for Artist Residencies

2.1 Installation of driver using Internet Installation of driver from disk... 3

Webbreg öppen: 26/ /

Swedish adaptation of ISO TC 211 Quality principles. Erik Stenborg

Writing with context. Att skriva med sammanhang

Theory 1. Summer Term 2010

Grafisk teknik IMCDP IMCDP IMCDP. IMCDP(filter) Sasan Gooran (HT 2006) Assumptions:

Chapter 2: Random Variables

Information technology Open Document Format for Office Applications (OpenDocument) v1.0 (ISO/IEC 26300:2006, IDT) SWEDISH STANDARDS INSTITUTE

Styrteknik: Binära tal, talsystem och koder D3:1

This exam consists of four problems. The maximum sum of points is 20. The marks 3, 4 and 5 require a minimum

Solutions to exam in SF1811 Optimization, June 3, 2014

Analys och bedömning av företag och förvaltning. Omtentamen. Ladokkod: SAN023. Tentamen ges för: Namn: (Ifylles av student.

12.6 Heat equation, Wave equation

Styrteknik : Funktioner och funktionsblock

Kurskod: TAMS11 Provkod: TENB 28 August 2014, 08:00-12:00. English Version

Kurskod: TAMS28 MATEMATISK STATISTIK Provkod: TEN1 05 June 2017, 14:00-18:00. English Version

Grafisk teknik IMCDP. Sasan Gooran (HT 2006) Assumptions:

Accomodations at Anfasteröd Gårdsvik, Ljungskile

Vässa kraven och förbättra samarbetet med hjälp av Behaviour Driven Development Anna Fallqvist Eriksson

SVENSK STANDARD SS-EN ISO 19108:2005/AC:2015

Högskolan i Skövde (SK, JS) Svensk version Tentamen i matematik

State Examinations Commission

LUNDS TEKNISKA HÖGSKOLA Institutionen för Elektro- och Informationsteknik

SAMMANFATTNING AV SKILLNADER MELLAN VADHÅLLNINGSBESTÄMMELSER ATG (SVERIGE) OCH PHUMELELA (SYDAFRIKA)

Viktig information för transmittrar med option /A1 Gold-Plated Diaphragm

(D1.1) 1. (3p) Bestäm ekvationer i ett xyz-koordinatsystem för planet som innehåller punkterna

Documentation SN 3102

Annonsformat desktop. Startsida / områdesstartsidor. Artikel/nyhets-sidor. 1. Toppbanner, format 1050x180 pxl. Format 1060x180 px + 250x240 pxl.

Kvalitetsarbete I Landstinget i Kalmar län. 24 oktober 2007 Eva Arvidsson

Tentamen i Matematik 2: M0030M.

Grafisk teknik. Sasan Gooran (HT 2006)

Om oss DET PERFEKTA KOMPLEMENTET THE PERFECT COMPLETION 04 EN BINZ ÄR PRECIS SÅ BRA SOM DU FÖRVÄNTAR DIG A BINZ IS JUST AS GOOD AS YOU THINK 05

Vad är en databas? Databaser. Relationsdatabas. Vad är en databashanterare? Vad du ska lära dig: Ordlista

LARS. Ett e-bokningssystem för skoldatorer.

Adding active and blended learning to an introductory mechanics course

F ξ (x) = f(y, x)dydx = 1. We say that a random variable ξ has a distribution F (x), if. F (x) =


Make a speech. How to make the perfect speech. söndag 6 oktober 13

Configuration Management

CM FORUM. Introduktion till. Configuration Management (CM) / Konfigurationsledning. Tobias Ljungkvist

Exam Molecular Bioinformatics X3 (1MB330) - 1 March, Page 1 of 6. Skriv svar på varje uppgift på separata blad. Lycka till!!

Småprat Small talk (stressed vowels are underlined)

denna del en poäng. 1. (Dugga 1.1) och v = (a) Beräkna u (2u 2u v) om u = . (1p) och som är parallell

Libers språklåda i engelska Grab n go lessons

Second handbook of research on mathematics teaching and learning (NCTM)


Tentamen i Matematik 2: M0030M.

Problem som kan uppkomma vid registrering av ansökan

Questionnaire for visa applicants Appendix A

Komponenter Removed Serviceable

Förändrade förväntningar

Authentication Context QC Statement. Stefan Santesson, 3xA Security AB

Metodprov för kontroll av svetsmutterförband Kontrollbestämmelse Method test for inspection of joints of weld nut Inspection specification

PORTSECURITY IN SÖLVESBORG

Skyddande av frågebanken

RUP är en omfattande process, ett processramverk. RUP bör införas stegvis. RUP måste anpassas. till organisationen till projektet

Quick Start Guide Snabbguide

CUSTOMER READERSHIP HARRODS MAGAZINE CUSTOMER OVERVIEW. 63% of Harrods Magazine readers are mostly interested in reading about beauty

Datasäkerhet och integritet

Consumer attitudes regarding durability and labelling

Stad + Data = Makt. Kart/GIS-dag SamGIS Skåne 6 december 2017

Hur fattar samhället beslut när forskarna är oeniga?

Transaktioner och samtidighet

Every visitor coming to the this website can subscribe for the newsletter by entering respective address and desired city.

Provlektion Just Stuff B Textbook Just Stuff B Workbook

Examensarbete Introduk)on - Slutsatser Anne Håkansson annehak@kth.se Studierektor Examensarbeten ICT-skolan, KTH

Translation Changes in Swedish EBSCOhost Interface

TDDB48 Databasteknik

Transkript:

Uppsala universitet Institutionen för informationsteknologi Kjell Orsborn, Tore Risch Tentamen 2004-04-14 DATABASTEKNIK - 1DL116, 1MB025 Datum...Onsdagen den 14 April, 2004 Tid...8:00-13:00 Jourhavande lärare...kjell Orsborn, tel. 471 11 54 eller 070 425 06 91 Hjälpmedel...miniräknare Anvisningar: Läs igenom hela skrivningen och notera eventuella oklarheter innan du börjar lösa uppgifterna. Förutom anvisningarna på skrivningsomslaget så gäller följande: Skriv tydligt och klart. Lösningar som inte går att läsa kan naturligtvis inte ge några poäng och oklara formuleringar kan dessutom misstolkas. Antaganden utöver de som står i uppgiften måste anges. Gjorda antaganden får förstås inte förändra den givna uppgiften. Skriv endast på en sida av papperet och använd ett nytt papper för varje uppgift för att underlätta rättning och minska risken för missförstånd. För godkänt krävs det cirka 50% av maxpoäng. 1

1. Database terminology: 4pts Concisely explain the following concepts (in a database context): (a) primary key A primary key is a minimal super key that is chosen among the candidate keys to become the key of a relation. A minimal super key consists of a minimal subset of the attributes of a relation that uniquely identifies all tuples in the relation. 1p (b) 3NF A relation schema is in 3NF if it is in 2NF and if no nonkey attribute in the schema is fully functional dependent of any other non-key attribute. 1p 2. Data models: 4pts Explain, and give examples of, what is meant by the two concepts physical and logical data independence that can be accomplished through the three-schema architecture. Fysiskt dataoberoende är förmågan att kunna förändra det interna schemat utan att behöva förändra det konceptuella (ej heller det externa) schemat. Ett exempel kan vara att man vill definera ett index över ett attribut i en tabell för att snabba upp sökningen av vid frågor som inbegriper detta attribut. Dessa frågor behöver alltså inte definieras om för att utnyttja detta index. Logical data independence: the possibility to change the conceptual schema without influencing the external schemas (views). e.g. add another field to a conceptual schema. 3. Relational model - integrity constraints: 4pts Explain in the context of the relational model the following concepts: (a) entity integrity Entitetsvillkor uttrycker att ingen primärnyckel får anta värdet NULL så att alla tupler i en relation kan identidieras unikt. 2p (b) referential integrity Referensintegritet kräver att om en tupel i en relation refererar till en annan relation så måste den referera till en existerande tupel. 2p 4. Relational algebra and SQL: 2pts Express the following query in two variants, with and without using a nested subquery, with the help of the relational schema below: 2

Find the names of all warehouses that have greater areas than some warehouse located in Uppsala. warehouse (wh-name,wh-city,area) select distinct T.wh-name from warehouse as T, warehouse as S where T.area > S.area and S.wh-city = "Uppsala" select wh-name from warehouse where area > some (select area from warehouse where wh-city = "Uppsala") 5. Conceptual data modeling: 4pts Describe the properties that one would like transactions to fulfill in a database context (hint: ACID). To preserve the integrity of data, the DBMS must ensure ACID properties: Atomicity (atomic or indivisible): a logic processing unit (all operations of the transaction) is carried out in its whole or not at all. Consistency (preservation): a correct execution of a transaction in isolation should preserve the consistency of the database (from one consistent state to another). Isolation: Although multiple transactions may execute concurrently, each transaction must be unaware of of other concurrently executing transactions. The updates of a transaction shall be isolated from other transactions until after the commit point. Durability (or permanency): If a transaction completes successfully, the changes it has made to the database must persist and should not be lost in a later system failure. 6. Security and Authorization: 4pts (a) How is authorization specified in modern relational databases? (b) Why are views useful for authorization? (c) When can a user transfer authorization rights to another user? (d) What is access matrix? a) by GRANT/REVOKE SQL commands that associates access rights with tables and views. b) Views make it possible to specify access rights covering subsets of tables or combinations of tables. E.g. dynamic access rights can be specifies where the accessible data depends on row values in tables. 3

c) A user can transfer access rights if those where granted to him using the annotation WITH GRANT OPTION. d) The access matrix is a 2D system object S x O -> R stating what access rights R a subject S has for objkect O. Subjects are e.g. users, accounts, roles. Objects are e.g. tables, views. Rights are e.g. READ, WRITE, UPDATE. 7. Object-Oriented and Object-Relational Databases: 4pts (a) What are the three most important kinds of user-definable database extensibility mechanisms available in an object-relational database system? (3 p) (b) Which one of the above extensibility mechanisms is lacking in an object-oriented kind of database system (an object store )? (1 p) a) User-defined functions (methods). User-defined storage representations. User-defined query optimization methods. b) User-defined query optimization methods 8. Active Databases: 4pts (a) What are the kinds of problems where ECA rules should not be used? Motivate why not. (2p) (b) Give an example of a problem where ECA rules should be used. Motivate why. (2p) a) Where queries can be used instead Where updates can be used instead Where stored procedures can be used instread b) Problems where a certain action should always be execution whenever a certain kind of update of the database is made. The action should be independent on who makes the update. For example, a travel agent might maintain a waiting list and whenever someone (e.g. other agent agent) cancels a suitable booking the system should automatically book someone from the waiting list. 9. Query Processing: 4pts We have a table PERSONS(SSN, NAME) SSN is key and the table is clustered on SSN. There is a B-tree index on NAME. Given the query 4

select SSN from PERSON where NAME = "KALLE" (a) What two execution plans are possible? (1 p) (b) Give exact formula stating which plan is faster in terms of parameters of the physical representation of the table in the database. When are they equally fast? (3p) a) project(ssn,select(rowscan(person),name="kalle")) project(ssn,indexscan(person.name="kalle")) b) N number of rows in PERSON B number of rows per table block I number of rows per index block d distinct values of NAME, d<=n, Assume m rows match KALLE, m = N/d on average. Cost of reading block from disk is 1. Number of blocks in table is N/B. Therefore depth of index is logi(d) (logi = I:th logarithm) Plan 1: N/B (must scan it all since there can be > 1 KALLE) Plan 2: logi(d) + m = logi(d) + N/d (assume one KALLE in index, m in rows) Equally fast when N/B = logi(d) + N/d This can happen when m is large, i.e d small and thus many persons in the table are called KALLE. Good luck! / Kjell och Tore 5