Data Collection and DBMS

Database Storage, Structured Data and Systematic Data Collection

PGCP-BDA

database storage

The organization of records, pages, indexes, logs and metadata on persistent media under DBMS control.

page and record

A page is the database unit transferred between storage and memory; records are the row representations stored inside pages.

buffer pool

A memory cache that keeps database pages in RAM and coordinates page replacement, dirty-page writing and concurrent access.

structured semi-structured unstructured data

Structured data follows a fixed schema, semi-structured data carries flexible tags or keys and unstructured data lacks a predefined tabular organization.

data source

A system, file, device, service or observation from which data is collected.

data collection method

A defined procedure for obtaining measurements or records, including instruments, sampling and validation.

sampling and observation

Sampling selects units from a population; observation measures variables on the selected units without imposed treatment.

measurement quality

The degree to which collected values are accurate, complete, consistent, valid, timely and fit for their intended analysis.

data provenance

Metadata describing where data originated, which transformations it underwent and which systems or people handled it.

data governance

The framework of ownership, policies, standards and controls used to manage data quality, access, security and lifecycle.

Clustered InnoDB Storage

InnoDB normally organizes table records by primary key. The clustered index's leaf records contain the row data.

Secondary index entries contain their secondary key plus the primary-key value used to locate the clustered record. Therefore, a wide primary key enlarges every secondary index.

Database Accounts

MySQL accounts combine a user name and host identity. Authentication verifies an account, while authorization determines what it may do.

Applications should use dedicated accounts rather than administrator credentials. Different services and environments should have separate identities so permissions and activity can be controlled and audited.

Use supported authentication plugins, secure connections, secret storage and credential rotation. Never embed unrestricted production passwords in source code.

Physical Data Models

A physical model describes how a particular database product will implement and access the logical design. It includes vendor data types, indexes, partitioning, storage engines, tablespaces, clustering, compression and placement choices.

Physical design depends on actual workload. An index that speeds frequent lookup consumes storage and adds work to inserts and updates. Partitioning that helps large historical queries may complicate other operations.

Conceptual, logical and physical designs are connected but should remain distinguishable. A physical optimization should not silently change business meaning.

Logging and Recovery

Undo information supports rollback and consistent historical reads. Redo information records changes needed to recover committed work after a crash.

The binary log records server changes for replication and point-in-time recovery according to configuration. It serves a different role from InnoDB redo and undo.

Crash recovery is not a replacement for tested backups. Backup procedures must capture a consistent state and retain the logs needed for the desired recovery point.

Client-Server Architecture

MySQL commonly runs as a database server process. A client connects using a network or local protocol, authenticates, sends SQL statements, receives results and manages transaction state.

The server parses SQL, checks names and privileges, chooses an execution plan, accesses data through a storage engine, applies constraints and returns results. This separation allows command-line tools, graphical tools, applications and administrative utilities to work with the same server.

In a three-tier application, a presentation client calls an application server, which contains business logic and connects to the database. This architecture avoids distributing database credentials and rules to every user interface.

Query Processing

When the server receives a query, it generally performs several conceptual stages:

  1. parsing checks syntax and forms an internal representation;
  2. semantic analysis resolves tables, columns, types and privileges;
  3. optimization considers equivalent plans and estimates cost;
  4. execution obtains rows through storage and access methods;
  5. result processing returns rows or an update status.

Declarative SQL describes the required result rather than a fixed procedural access path. The optimizer may use an index, scan a table, reorder joins or choose another equivalent strategy.

Continue learning

Related notes

Put this topic into timed practice

Open mock tests when you want full-exam pacing, or keep drilling in practice mode.