Tentamen DATABASE TECHNOLOGY - 1MB025

Relevanta dokument
Final Exam DATABASE TECHNOLOGY - 1DL300

Tentamen DATABASTEKNIK - 1DL116, 1MB025

Database course summary

Tentamen DATABASTEKNIK - 1DL116, 1MB025

Tentamen DATABASTEKNIK - 1DL116

Tentamen DATABASTEKNIK - 1DL116, 1MB025

Tentamen DATABASTEKNIK - 1DL116, 1MB025, 1DL124

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

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

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.

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

Isometries of the plane

Isolda Purchase - EDI

TDDB 48 Database technology

Support for Artist Residencies

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

Preschool Kindergarten

Module 1: Functions, Limits, Continuity

Svar till tentamen DATABASTEKNIK - 1DL poäng

Datasäkerhet och integritet

DVG C01 TENTAMEN I PROGRAMSPRÅK PROGRAMMING LANGUAGES EXAMINATION :15-13: 15

6 th Grade English October 6-10, 2014

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


Taking Flight! Migrating to SAS 9.2!

Beijer Electronics AB 2000, MA00336A,

Module 6: Integrals and applications

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

x 2 2(x + 2), f(x) = by utilizing the guidance given by asymptotes and stationary points. γ : 8xy x 2 y 3 = 12 x + 3

LARS. Ett e-bokningssystem för skoldatorer.

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

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

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

Solutions to exam in SF1811 Optimization, June 3, 2014

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

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

A metadata registry for Japanese construction field

Introduktion till Entity Framework och LINQ. Källa och läs mer

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

EXTERNAL ASSESSMENT SAMPLE TASKS SWEDISH BREAKTHROUGH LSPSWEB/0Y09

Swedish adaptation of ISO TC 211 Quality principles. Erik Stenborg

Immigration Studying. Studying - University. Stating that you want to enroll. Stating that you want to apply for a course.

TDDB 38 Database technology

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

Karlstads Universitet, Datavetenskap 1

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

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

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

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

Webbregistrering pa kurs och termin

CHANGE WITH THE BRAIN IN MIND. Frukostseminarium 11 oktober 2018

Support Manual HoistLocatel Electronic Locks

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

Adding active and blended learning to an introductory mechanics course

Syns du, finns du? Examensarbete 15 hp kandidatnivå Medie- och kommunikationsvetenskap

District Application for Partnership

The Finite Element Method, FHL064

Tentamen i Matematik 2: M0030M.

Directorate of Education Govt. of NCT of Delhi. Support Material Political Science Class-XI(Urdu Medium)

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

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

Skyddande av frågebanken

Det finns en handledning till kortet på hemsidan. AVR STK500.

EVALUATION OF ADVANCED BIOSTATISTICS COURSE, part I

Theory 1. Summer Term 2010

Thesis Production Time plan, preparation and Word templates

Grafisk teknik. Sasan Gooran (HT 2006)

Kursplan. MT1051 3D CAD Grundläggande. 7,5 högskolepoäng, Grundnivå 1. 3D-CAD Basic Course

1. Find an equation for the line λ which is orthogonal to the plane

Scalable Dynamic Analysis of Binary Code

Measuring child participation in immunization registries: two national surveys, 2001

Datorteknik och datornät. Case Study Topics

Dokumentnamn Order and safety regulations for Hässleholms Kretsloppscenter. Godkänd/ansvarig Gunilla Holmberg. Kretsloppscenter

Michael Q. Jones & Matt B. Pedersen University of Nevada Las Vegas

What Is Hyper-Threading and How Does It Improve Performance

Blueprint Den här planeringen skapades med Blueprints gratisversion - vänligen uppgradera nu. Engelska, La06 - Kursöversikt, 2015/2016.

2(x + 1) x f(x) = 3. Find the area of the surface generated by rotating the curve. y = x 3, 0 x 1,

6. a) Visa att följande vektorer är egenvektorer till matrisen A = , och ange motsvarande

The Municipality of Ystad

Övning 5 ETS052 Datorkommuniktion Routing och Networking

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

E: 9p D: 10p C: 14p B: 18p A: 22p

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

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

Consumer attitudes regarding durability and labelling

Configuration Management

EXPERT SURVEY OF THE NEWS MEDIA

Webbreg öppen: 26/ /

Det här med levels.?

COPENHAGEN Environmentally Committed Accountants

Klassificering av brister från internaudit

and u = och x + y z 2w = 3 (a) Finn alla lösningar till ekvationssystemet

research en användarundersökning

Förskola i Bromma- Examensarbete. Henrik Westling. Supervisor. Examiner

Hållbar utveckling i kurser lå 16-17

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

PFC and EMI filtering

S 1 11, S 2 9 and S 1 + 2S 2 32 E S 1 11, S 2 9 and 33 S 1 + 2S 2 41 D S 1 11, S 2 9 and 42 S 1 + 2S 2 51 C 52 S 1 + 2S 2 60 B 61 S 1 + 2S 2 A

Translation Changes in Swedish EBSCOhost Interface

Installation av F13 Bråvalla

Transkript:

Uppsala University Department of Information Technology Kjell Orsborn, Tore Risch Tentamen 2005-12-21 DATABASE TECHNOLOGY - 1MB025 Date... Wednesday 21 December, 2005 Time... 08:00-13:00 Teacher on duty... Kjell Orsborn, phone 471 11 54 or 070 425 06 91 Exam aids... calculator Instructions: Read through the complete exam and note any unclear directives before you start solving the questions. The following guide lines hold: Write clear and neat answers! Answers that cannot be read can obviously not result in any points and unclear formulations can be misunderstood. Assumptions outside of what is stated in the question must be explained. Any assumptions made should not alter the given question. Write your answer on only one side of the paper and use a new paper for each new question to simplyfy the correction process and to avoid possible misunderstandings. A passing grade requires about 50% of the maximum number of points. 1

1. Database terminology: 4 pts Explain the following database concepts: (a) meta data Answer: Meta data, or the database schema, include data about data, i.e. a description of the database stored in the system catalog. Meta-data consist of information about structure of files, type and storage format of each data item, various constraints on the data and other types of information about data such as authorization privileges and access statistics. For the relational model this include descriptions of the relation names, attribute names, data types, primary keys, secondary keys, foreign keys, other constraints, views, storage structures and indexes, and security and authorization information. (b) primary index Answer: Primärindex består av en ordnad fil av dataposter med 2 fält. Första fältet är av samma typ som ordningsfältet (indexeringsfältet) för datafilen och det andra fältet är en pekare till ett datablock (blockpekare). Primärindex är ett glest index då det har en indexpost för varje block i data-filen. Primärindex kräver mycket mindre plats än motsvarande datafil och kan utnyttjas för att snabba upp sökningen av dataposter i datafilen med avseende på indexeringsfältet. (c) referential integrity (sv. referensintegritet) Answer: Referensintegritet kräver att om en tupel i en relation refererar till en annan relation så måste den referera till en existerande tupel. (d) full functional dependency (sv. fullt-funktionellt beroende) Answer: Ett funktionellt beroende så att X bestämmer Y, X - Y, existerar då om för varje par av tupler t 1, t 2 r(r) och för alla r(r) följande gäller: om t 1 [X] = t 2 [X] så gäller att t 1 [Y ] = t 2 [Y ] Fullt funktionellt beroende anger att för ett funktionellt beroende gäller att det inte finns någon delmängd attribut A X så att (X {A})Y. Här gäller att R är ett relationsschema och r(r) är en instans av schemat R med attributen A 1,..., A n och X, Y {A 1,..., A n }. Alltså ett fullt funktionellt beroende är ett funktionellt beroende som inte innehåller något onödigt attribut i determinanten (vänsterledet i beroendet). 2. Data models - three schema architecture: 4 pts Explain and give examples on what is meant by the concepts physical and logical data independence. Answer: The three-schema architecture introduces a multi-level architecture where each level represents one abstraction level - in 1978 the standard architecture (ANSI/SPARC architecture) for databases was introduced. It consists of 3 levels where each level introduces one abstraction layer and has a schema that describes how representations should be mapped to the next lower abstraction level: 1) The internal level or internal schema - describes storage structures and access paths for the physical database. Abstraction level: files, index files etc. Is usually defined through the data definition language (DDL) of the DBMS. 2) Conceptual level or conceptual schema - an abstract description of the physical database. Constitute one, for all users, common basic model of the logical content of the database. This abstraction level corresponds to the real world : 2

object, characteristics, relationships between objects etc. The schema is created in the DDL according to a specific data model. 3) External level, external schemas, or views - a typical DB has several users with varying needs, demands, access privileges etc. External schemas describes different views of the conceptual database with respect to what different user groups would like to/are allowed to se. Some DBMSÕs have a specific language for view definitions (else the DDL is used). Physical data independence: the possibility to change the internal schema without influencing the conceptual schema. E.g. the effects of a physical reorganization of the database, such as adding an access path, is eliminated. 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. Physical database design - indexing: 4 pts (a) Describe the structure of B+ trees Answer: Ett B+-träd består av en balanserad trädstruktur med en ordnad mängd noder med sökvärden: en rot, inre noder och lövnoder. Ordningstalet p på trädet avgör storleken på trädet där inre noder har som minst p/2 och som mest p trädpekare (utom roten). Vidare har en inre nod med q st pekare (where q < p) q 1 st sökvärden. Interna noder består av en ordnad mängd av pekare p och sökvärden k enligt < p 1, k 1, p 2, k 2,..., p q l, k q 1, p q >, där k 1 < k 2 <... < k q. För alla sökvärden x i ett delträd pekat på från p i gäller att k i 1 < x k 1 för 1 < i < q; x k i för i = 1; och k i 1 < x för i = q. Lövnoderna har strukturen << pr 1, k 1 >, < pr 2, k 2 >,..., < pr q l, k q 1, > pr next > där q < p, varje pr i är en datapekare (eller datablock-pekare) och pr next pekar vidare till nästa lövnod. Löven finns alla på samma nivå och innehåller minst p/2 värden. (svaret kan ges en mycket mer kortfattat form mha figurer). (b) Describe the principle for retrieval of data records by using a B+ tree index. 4. SQL and relational algebra: 4 pts Assume that we have a litterature database where there are two relations (tables) with the following schemas: BOOK(BID, BNAME) CHAPTER(CID, CNAME, LENGTH, BOID), where xid s represents keys. (a) Formulate a query in relational algebra that retrieves book id, book name, chapter id, chapter name and the length of the chapters for the book Guide Uppsala. (2p) (b) Formulate an SQL query that retrieves the book id, book name, and the number of chapters for each book, i.e. how many chapters each book consists of. (2p) 3

Answer: π <BID,BNAME,CID,CNAME,LENGT H> (σ BNAME= GuideUppsala (BOOKX <BID=BOID>CHAP T ER)) SELECT B.BID,B.BNAME, COUNT(*) AS NO_OF_ CHAPTERS FROM BOOK B, CHAPTER C WHERE B.PID = C.BOID GROUP BY BID,BNAME 5. Concurrency control (sv. samtidighetskontroll): 4 pts (a) Describe the principles for lock management (sv. låshantering) for transactions controlled by a two-phase locking protocol (sv. två-fas låsningsprotokoll). Answer: En transaktion sägs följa ett två-fas låsningsprotokoll om alla låsningsoperationer föregår den färsta upplåsningsoperationen (unlock) i transaktionen. Alltså en sådan transaktion genomgår en expanderande fas där nya lås kan utfärdas men inga lås kan släppas; och en krympande fas där existerande lås kan låsas upp men inga nya lås kan erhållas. (b) What important properties can be stated by transaction schedules controlled by two-phase locking protocols? Answer: Två-fas låsningsprotokoll garanterar serialiserbara transaktionsscheman men garanterar ej frihet från deadlocks. 6. Object-oriented and object-relational databases: 4 pts (a) What is the purposes of the three main kinds of user-definable database extensibility mechanisms available in an object-relational database system (sv. objektrelationella databaser )? (b) Which of the above extensibility mechanisms are lacking or weak in a first generation object-oriented database system, i.e. in object stores (sv. objektlager )? 7. Query optimization: 4 pts (a) What is selectivity (sv. selektivitet ) and how is it used in cost-based query optimization? (b) What is the worst case complexity of cost-based query optimization and how does one avoid this cost? (c) Why does cost-based query optimization pay off despite its complexity? (d) How are operators in execution plans different from relational algebra operators? Give examples. 8. ODBC: 4 pts (a) What is ODBC? (b) What is the difference between JDBC and ODBC? 4

(c) What is an ODBC driver (sv. drivrutin )? (d) What is the purpose of the ODBC driver manager? Good luck and a Merry, Merry Christmas! / Kjell och Tore 5