What is the total i/o cost for sorting this file

Assignment Help Database Management System
Reference no: EM13336570

Suppose that you just finished inserting several records into a heap file and now want to sort those records. Assume that the DBMS uses external sort and makes efficient use of the available buffer space when it sorts a file. Here is some potentially useful information about the newly loaded file and the DBMS software available to operate on it:

The number of records in the file is 4500. The sort key for the file is 4 bytes long.

You can assume that rids are 8 bytes long and page ids are 4 bytes long. Each

record is a total of 48 bytes long. The page size is 512 bytes. Each page has 12

bytes of control information on it. Four buffer pages are available.

1. How many sorted subfiles will there be after the initial pass of the sort, and how long will each subfile be?

2. How many passes (including the initial pass just considered) are required to sort this file?

3. What is the total I/O cost for sorting this file?

4. What is the largest file, in terms of the number of records, you can sort with just four buffer pages in two passes? How would your answer change if you had 257 buffer pages?

5. Suppose that you have a B+ tree index with the search key being the same as the desired sort key. Find the cost of using the index to retrieve the records in sorted order for each of the following cases:

• The index uses Alternative (1) for data entries.

• The index uses Alternative (2) and is unclustered. (You can compute the worst case cost in this case.)

• How would the costs of using the index change if the file is the largest that you can sort in two passes of external sort with 257 buffer pages? Give your answer for both clustered and unclustered indexes.3

Reference no: EM13336570

Questions Cloud

Compiler design problem : This is done by changing the CFG that the language uses and what changes would have to be made to ac's CFG
Identify a relational algebra tree : Identify a relational algebra tree (or a relational algebra expression if you prefer) that reflects the order of operations a decent query optimizer would choose.
Compute the magnitude of the magnetic flux through the loop : A solenoid with 1200 turns per meter has a diameter of 9.00 cm. A current I = 2.57 A flows in the clockwise direction, Find the magnitude of the magnetic flux through the loop
What is the cost of joining r and s using a sort-merge join : What is the cost of joining R and S using a page-oriented simple nested loops join? What is the minimum number of buffer pages required for this cost to remain unchanged?
What is the total i/o cost for sorting this file : How many sorted subfiles will there be after the initial pass of the sort, and how long will each subfile be?
What is the carts final velocity : A 100 N force has a horizontal component of 60 N and a vertical component of 80 N. What is the cart's final velocity
Calculate the pressure of the gas on the walls : One mole of oxygen molecules occupies a cubic vessel of side length 10 cm at a temperature of 18 C. Calculate the pressure of the gas on the walls
List whether the index matches the given selection condition : Athabasca University has about 32,000 students between the ages of 17 to 60. Consider the AU student relation with the following schema.
Find an expression for the velocity vs distance : Find an expression for the velocity vs. distance.

Reviews

Write a Review

Database Management System Questions & Answers

  Examine the use of databases in organization

Create a 2-3 page (350 words per page) examining the use of databases in organization. Explain what database applications are utilized (Microsoft Access, DB2, Oracle, etc.).

  Discuss the costs involved in implementing the database

Using the SafeAssign link in Blackboard to submit your report. Download and print out the FULL report and attach to the appendix at the back of your report. Assignments without the full SafeAssign report will NOT be marked.

  Develop a domain model for the case study

The objective of the assignment is to apply and consolidate skills acquired in the requirement and analysis disciplines through analysis of a simple case study, and to express the results through the relevant UML diagrams.

  An active database in pl-sql

Did the corresponding lines for invoices 1001 and 1008 in table LINE get deleted automatically? Can you explain why?

  Sketch dfsa for identifiers-contain only letters and digits

Sketch a DFSA for identifiers which contain only letters and digits, where identifier should have at least one letter, but it need not be first character.

  Finance industry-based organization

Imagine that you work for a finance industry-based organization. Your organization is looking to submit its database design documentation to an evaluation team in order to meet Sarbanes-Oxley (SOX) compliance

  Security associated with new project

Your company has put in the request for a new database system and you have been tasked with architecting the security associated with this new project.

  Establish a single control transport connection

This connection would be used to carry control signals relating to all user transport connection between the two entities. Discuss the implications of this strategy.

  Creating erd containing order and customer entity

Create ERD containing Order and Customer entity types connected by 1-M relationship from Customer to Order. Select suiatble relationship name using your common knowledge of intersection.

  Describe the content, purpose, user access methods

describe the content, purpose, user access methods, and sources of data

  Case - max in the state department

Construct a diagram using Rationale to map the arguments about a moral claim that you have identified in the article/case study and write an essay, which maps closely to the Rationale diagram that you constructed.

  Systems analysis and database design

Based on the information in the Bike Mania case study, use a suitable CASE tool or drawing package to draw up a set of diagrams showing the current physical view of the systemusing the unified modeling language (UML 2.0) notation

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