Calculate the record size r in bytes, Database Management System

Assignment Help:

An employee record has the following structure
struct employee {
int eno;
char name[22];
float salary;
char dept[10];};
(i) Calculate the record size R in bytes.
(ii) If the file has 500 records, calculate the blocking factor bfr and the number of blocks b, assuming an unspanned organization with block size B = 512 bytes.
(iii) Describe the unused space in each block and in the last block?

Ans: (i) 2 + 22+ 4 + 10 =38 bytes
(ii) bfr = floor( B/R) = [512/38] =13
Number of blocks b = ceiling (500/13) =39
(iii) Unused space in each block
= 512 - 38 *13 = 512 - 494= 18 bytes
Unused space in the last block
= ( 39 *13 - 500) * 38 bytes = (507 -500) * 38 bytes
= 7 * 38 =266 bytes


Related Discussions:- Calculate the record size r in bytes

Objectives-the structured query language, Objectives After reading this...

Objectives After reading this part, you should be able to: Modify, create, and delete database schema objects; Update database using SQL command; Retrieve data f

Mapping, external and internal mapping with examples

external and internal mapping with examples

Modelling and normalisation, Task Part A. Create an ERD from a business pro...

Task Part A. Create an ERD from a business problem. (50 marks) Read the following problem and complete the tasks listed below. THE ABS Blood Bank Australian Blood Services (ABS) i

Draw an entity-relationship model, Draw an Entity-Relationship model for ...

Draw an Entity-Relationship model for the relational schema given in the Appendix. Show all the entities, relationships, relationship names, and attributes and also underline the

Control as a state machine engine, Control as a State Machine Engine F...

Control as a State Machine Engine First let us define the state machine: "the state machine is a machine which is an object but not an application object. It is a part of lang

Having clause-data manipulation language, Having clause This clause...

Having clause This clause is used for producing conditions on grouped information. Example: Find maximum salary and department number of those departments where maxim

Explain the role of a database administrator, Explain the Role of a databas...

Explain the Role of a database administrator a. Defining the Schema   The DBA describes the schema which consists of the structure of the data in the application. The DBA

Explain group by clause in sql, Explain group By clause in SQL? Group B...

Explain group By clause in SQL? Group By clause in SQL: The GROUP BY clause can be used in a SELECT statement to collect data across multiple records and group the results thro

Emergence of client server architecture, Emergence of Client Server Archite...

Emergence of Client Server Architecture Some of the pioneering work that was completed by some of the relational database vendors permitted the computing to be distributed on m

What is alternate key, What is Alternate Key Alternate Key: This is t...

What is Alternate Key Alternate Key: This is the candidate key which is not taken as the primary key of the table. They are named so because although not the primary key, the

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd