Suppose that you have formatted your disk with a block size of 1024 bytes and assume that we have 10,000 CAR records of fixed length. A block pointer is 7 bytes long (P=7), and a record pointer is 5 bytes long (Pr=5). Each CAR record has the following fields: License_number (20 bytes), Model (8 bytes), Color (9 bytes), Brand (9 bytes), Location (40 bytes), Mileage (10 bytes), Price (8 bytes), Year (4 bytes), Manufacturer (16 bytes), and Remarks (200 bytes). The file is ordered by the key field License_number and we want to construct a primary index on License_number. (a) Calculate the blocking factor (bfr) and the number of file blocks needed to store the CAR records. Assume that records are stored unspanned. How much space remains unused per block? (b) Calculate the index blocking factor bfri. (c) Assume that the primary index is a single-level index. Calculate the number of index entries and the number of index blocks.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Topic Video
Question
7
Question 1.
Suppose that you have formatted your disk with a block size of 1024 bytes and assume
that we have 10,000 CAR records of fixed length. A block pointer is 7 bytes long (P=7),
and a record pointer is 5 bytes long (Pr=5). Each CAR record has the following fields:
License_number (20 bytes), Model (8 bytes), Color (9 bytes), Brand (9 bytes), Location
(40 bytes), Mileage (10 bytes), Price (8 bytes), Year (4 bytes), Manufacturer (16 bytes),
and Remarks (200 bytes). The file is ordered by the key field License_number and
we want to construct a primary index on License_number .
(a) Calculate the blocking factor (bfr) and the number of file blocks needed to store the
CAR records. Assume that recards are stored unspanned. How much space
remains unused per block?
(b) Calculate the index blocking factor bfri .
(c) Assume that the primary index is a single-level index. Calculate the number of
index entries and the number of index blocks.
Transcribed Image Text:Question 1. Suppose that you have formatted your disk with a block size of 1024 bytes and assume that we have 10,000 CAR records of fixed length. A block pointer is 7 bytes long (P=7), and a record pointer is 5 bytes long (Pr=5). Each CAR record has the following fields: License_number (20 bytes), Model (8 bytes), Color (9 bytes), Brand (9 bytes), Location (40 bytes), Mileage (10 bytes), Price (8 bytes), Year (4 bytes), Manufacturer (16 bytes), and Remarks (200 bytes). The file is ordered by the key field License_number and we want to construct a primary index on License_number . (a) Calculate the blocking factor (bfr) and the number of file blocks needed to store the CAR records. Assume that recards are stored unspanned. How much space remains unused per block? (b) Calculate the index blocking factor bfri . (c) Assume that the primary index is a single-level index. Calculate the number of index entries and the number of index blocks.
Expert Solution
steps

Step by step

Solved in 4 steps with 13 images

Blurred answer
Knowledge Booster
Instruction Format
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education