6. File Organisation Flashcards
What is a File and Record?
A file is a resource of storing data.
A record is a collection of fields that can store a single set of values
What is a Fixed Length Field and describe when it would be used
A fixed length field is a file where each record is of the same length. Used for records where each have fixed lengths (e.g. national insurance number). Makes file processing easier but may waste memory if not fully utilized.
What is Variable Length Field and describe when it would be used
Variable length fields only store characters that are needed (e.g. names). no wasted memory but more complicated to find data.
What’s a transaction file and a master file?
Transaction files will store data collected over a short amount of time. They act as a temporary file to help keep the system running quickly, but still storing all of the required data. At the end of a short time scale, the data is copied to the master file.
Master files are updated periodically and maintain long term record transactions. They also contain core data essential for operations.
What is a File Backup?
A backup file is a copy of computer data that is stored in an alternative location
What is a Serial File?
Records are stored in the order they are received and not sorted
+ Simplicity
+ easy locating records as only the record key is required
Best used for situations where ordering is not required e.g records times of runners crossing finishing line
What is a Sequential File
Sequential files store data in order of record key
+ Simplicity, easy to implement and use
- Slow and inefficient when working with large files
Best used for application that linearly process data such as reading or writing data to a log file.
What is Indexed Sequential?
In indexed sequential, records are split into two components - the record key and a pointer in one component, and the bulk of the record in another.
+ Speed and efficiency
- Requires additional storage space for index
For large files that require fast access to particular data elements
What is Direct access
Records can be stored in any order. The location of each record is computed from the records unique primary key.
+ Speed and efficiency
- more complex and difficult to implement and use
For applications that require quick and efficient access to specific records e.g. retrieving customer data based on customer ID
What is Full Backup
Backs up all data. Takes longest and uses the most resources
What is differential backup
Updates the last file that was updated. Efficient and fastest to create, but slower and less reliable when recovered.
What is incremental backup
Backs up only files that changed since the last full backup.
What are transaction logs?
Transaction logging is the practice of recording transactions in a separate portion of disk space from the main database. These records, known as log records, contain sufficient data to reverse all modifications made to the database during a transaction.
What is archiving
Moving the file or the record from the main system to a separate archived system. Its important because archiving old files speeds up the overall running, but still allows access to files when needed
Files should be archived if they take up to much space in the master a file or arent used regurarly. Before archving decide on a storage medium and order the files in a sequence.