DBMS - File Structures Flashcards
File
named collection of records stored. Usually resident on secondary storage units ex. Disk
File Processing
Management of these files ex. creation insertion, updating and deletion
Two main modes of processing
- Batch (as a whole)
- Online (one record at a time)
What to provide for in File Structures and Processing
- Design requirements
- Understanding a DBMS
- Comparison and comprehension of software
- Data Reorganization
- Query optimization purposes
File Processing trains designers with
analytical and engineering techniques
Need for file processing
- A Computation’s input and output can be larger than any main memory can hold
- A considerable amount of data sharing is required
- Persistent storage between bouts of file processing needed
Mechanism for data access from secondary devices
Different from main memory
Granularity of disk access
Cluster/Sector/Block based
Data on storage devices can get
Lost/Damaged from physical or logical events
Files placed on
Persistent storage devices. Secondary storage is not directly addressable for computation.
IO instructions between main and secondary storage
Specialized
Access time and magnitude
Has much larger magnitude than main memory accesses
Background insights
- The cost of secondary storage is decreasing
- The disk performances are improving (good cost performance ratio)
- One can easily replace a disk unit with another
Batch
comes in spans ex. end of day/week
Online/Transaction Model
Data processed as soon as it arrives. Activity load spread and users are catered at the same time.
Access Method
Program that implements selection criteria and navigation to manage data in a file or on behalf of an application program.
Types of Files
Master
Reference
Transaction
Temporary
Archive
Log Files
Master File
Used as an authority in a given job and is relatively permanent but can change.
Reference File
Usually with an array of data value pairs. A reference file’s intention is a more static master file, with less data content and access to its records must be the fasdtest
Transaction File
Used for a specific part of the business process. Processed with master and reference file(s).
Temporary File
Acts as a dynamic, structured, or transient space. Data usually created and purged within the span of the same procedure
Archive Files
Files record user and system actions, and historically relevant but now inert data
Log Files
Support transaction processing requirements
File protection
Loss of data due to programming or physical damage (but delimiting unlawful access)