GimmeJob
Sign in
Testing & diagnostic tools · Chapter 05 / 08

Testing & Diagnostic Tools

Database & data inspection

Database inspection is strongest when it answers a specific persistence question. A GUI such as DBeaver can browse schemas and run queries, but the transferable skill is safe SQL investigation and understanding transaction/state boundaries.

Observed UI/API value → identify entity/key → read-only query → inspect constraints/relations → compare source-of-truth timing/state → capture minimal evidence

Safe connection setup and read-only investigation habits

A database client can expose production-like data and powerful mutation capabilities. Connection profiles should make environment identity obvious and use the least privilege required for the investigation.

Practical use: Prefer read-only credentials for investigation, show host/database/schema visibly, and validate the target before running any query copied from elsewhere.

Caveat: A familiar database name is not enough to identify an environment; endpoints and credentials can change.

Querying, filtering and inspecting schema and constraints

Schema browsing reveals tables, columns, types, keys and constraints; targeted SELECT queries show stored records. Together they help distinguish invalid persistence from API mapping or UI presentation defects.

Practical use: Query by stable identifiers and select only relevant columns. Inspect foreign keys, uniqueness and nullability when the defect involves relationships or validation.

Caveat: SELECT * on large or sensitive tables is poor evidence and may create unnecessary load or data exposure.

Transactions and accidental-write risk

Transactions control when a set of database changes becomes durable and visible. A SQL client can execute writes immediately depending on auto-commit settings, so the tester must know whether a query is observational or mutating.

Practical use: Check auto-commit and transaction mode before any allowed write. For investigation, prefer SELECT and database-side read-only enforcement rather than relying on personal discipline.

Caveat: A rollback is not a universal safety net: external effects, sequences, triggers or other sessions may make a mutation observable.

Exporting evidence and reconciling API/UI results with stored data

Reconciliation compares representations of the same business fact across layers: database row, service response and UI. Differences can reveal caching, eventual consistency, transformation or stale-client defects.

Practical use: Record identifiers and timestamps at each layer and account for expected propagation delay. Export only the rows/columns needed for the defect.

Caveat: The database is not always the sole source of truth; event-sourced, replicated or cached systems require understanding the data architecture.
DBeaver investigation flow — read first and make production writes difficult

A SQL client can answer whether persisted state agrees with API/UI evidence, but the investigation itself should not accidentally mutate live data.

  1. In Database Navigator, select the intended connection and verify its environment.
  2. Open an SQL editor for that connection and begin with a narrow SELECT using deterministic identifiers and a sensible result limit.
  3. Compare returned IDs, status fields, timestamps, and relationships with the API/UI evidence.
  4. Check the connection’s transaction behavior. For an existing connection: right-click it → Edit Connection → Connection settings → Initialization. DBeaver exposes Auto-commit there.
  5. Use an environment-specific Connection type. Current DBeaver defaults define Production with AutoCommit off and confirmations for SQL execution/data changes, while new connections use Development unless changed. Verify the actual connection rather than assuming its type.
  6. If you only need evidence, stop after the read.

Official DBeaver initialization settings · Official DBeaver connection types

Summary

  • This chapter covers 4 required concepts while keeping tool/formula details tied to a practical decision.
  • Definitions, scope, assumptions and caveats matter more than a number or a tool name by itself.
  • Claims that depend on a standard or product are grounded in the source registry below.

Source registry

Verified 16 Aug 2026
DBeaver documentation

Database connections, schema browsing, querying and safe data export

DBeaver Corp · verified
Source ↗
PostgreSQL 18 SQL tutorial

Relational querying, joins, updates and SQL investigation fundamentals

PostgreSQL Global Development Group · verified
Source ↗
PostgreSQL 18 transaction documentation

Transaction, COMMIT/ROLLBACK and visibility concepts used in safe database investigation

PostgreSQL Global Development Group · verified
Source ↗