FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour SQL vs. DBF – A Philosophical Reflection
Posts: 7020
Joined: Fri Oct 07, 2005 07:07 PM

SQL vs. DBF – A Philosophical Reflection

Posted: Mon Feb 02, 2026 10:20 AM

DBF and SQL represent two different attitudes toward data.

DBF corresponds to a fixed SSD mounted to the case.
The file is visibly present in the file system. You know where it is, when it is opened, who locks it, and when it is released again. Proximity here is not a convenience feature, but part of the mental model. Control is direct, not mediated.

SQL corresponds to outsourcing into a service.
The data disappears behind a layer of abstraction: server, engine, transactions, optimizer. You send a request and receive an answer—what happens in between remains invisible. This is powerful, but it creates distance.

The difference is subtle, but decisive. Outsourcing creates distance. Responsibility is shifted into a realm where ownership becomes abstract and control turns into assumption. Proximity, by contrast, is concrete. What remains visible and physically present resists alienation.

Ownership here is not a legal category, but an attitude. Data that you can see and that has a fixed place remains part of your own workspace—and thus part of your own responsibility. It is not “somewhere else,” it is here, just newly arranged.

Fixing something to the case is therefore more than a practical gesture. It is a quiet commitment to control. The data is not removed from the system, but deliberately anchored within it. Order does not arise from removal, but from structure.

In a digital world that often equates storage with invisibility, this act feels almost archaic. And that is precisely where its strength lies: proximity creates trust, reliability, and clarity.

DBF vs. SQL – a question of proximity, not just technology

The difference between DBF and SQL is not only technical, but above all an attitude toward data.

DBF stands for proximity.
The file is visible, tangible, part of the file system. You open it deliberately, lock it explicitly, write to it, and close it again. Responsibility is direct and traceable. You know where the data is and when you are working with it.

SQL stands for abstraction.
The data resides behind an engine, behind transactions, optimizers, and server processes. You formulate intentions and trust that the system executes them correctly. Control is mediated, not exercised.

Both are legitimate.
SQL scales extremely well; DBF offers immediate transparency.

That is why many developers perceive DBF not as “outdated,” but as close.
Not out of nostalgia, but because cause and effect directly coincide. Errors are visible, states are comprehensible, processes can be mentally modeled.

Similar to locally fixed data:
You do not part with it, you simply arrange it differently.

Perhaps DBF is less a database question than an architectural and trust question.

The images show not loose peripherals, but deliberate fixation.
The industrial Velcro turns the external SSD from an accessory into a component of the system. It does not dangle from a cable, it does not lie somewhere beside it—it is anchored. This very act of anchoring transforms “external” into “belonging.”

The direction of the decision is also striking:
Technology does not dominate the workspace; the workspace incorporates the technology. The SSD integrates itself, it gets a place, an orientation, a relationship to the computer. This is the opposite of outsourcing.

The second image reinforces the motif of proximity:
Laptop, cable, SSD—everything remains within a manageable radius. Nothing disappears behind furniture or into drawers. The flow of data is visible, traceable, almost physically perceptible. The system feels calm and self-contained.

Thus a quiet architectural statement emerges:
Data does not need a place where it disappears, but a place where it is allowed to remain.
Fixed here does not mean immobile, but accountable.

As with DBF versus SQL:
The data is not hidden behind a layer, but part of the visible structure. You know where it is—and precisely because of that, you also know what you are responsible for.

The photos therefore do not show a makeshift solution, but an attitude:
Order through proximity.
Control through visibility.
Ownership through relationship.

Both have their justification.
But they feel fundamentally different.

DBF is like working at a workbench:
You reach for it, lock it, modify it, put it back. Responsibility is immediate. Errors are visible, but also understandable.

SQL is like working through a control room:
You formulate intentions, delegate execution, and trust that the system behaves correctly. Control becomes configuration.

That is why many DBF developers feel closer to their data—even if SQL is objectively more powerful. It is not about nostalgia, but about relationship.

Just like with the fixed SSD:
You do not part with the data.
You simply decide how close you want to remain to it.

Posts: 0
Joined: Wed Aug 26, 2026 09:41 AM

Re: SQL vs. DBF – A Philosophical Reflection

Posted: Sun Aug 30, 2026 06:58 PM

This is a beautifully articulated reflection. You've captured something that many Harbour/FiveWin developers feel intuitively but rarely put into words: DBF isn't "legacy"—it's a different contract with your data.

A few technical notes that align with your philosophy:

Where DBF's proximity pays off:
- Deterministic behavior — RLOCK(), FLOCK(), DBUNLOCK() map 1:1 to your mental model. No phantom locks, no transaction isolation surprises.
- Zero-config deployment — Copy the .dbf/.cdx/.fpt files, done. No service, no port, no credentials, no firewall rules.
- Inspectability — TYPE() a record, MEMOEDIT() a blob, INDEX ON with a code block. The debugger is the data.

Where SQL's abstraction earns its keep:
- Concurrency at scale — MVCC, row-level locking, connection pooling. DBF's shared-mode locking tops out around 20–50 concurrent users on a LAN.
- Set-based logic — UPDATE ... JOIN ... WHERE replaces loops that would be O(n²) in xBase.
- Integrity by declaration — FK constraints, CHECK, triggers. In DBF you code integrity; in SQL you declare it.

The hybrid reality most FiveWin apps live in:

// Local config, session state, offline queue → DBF
USE (AppPath() + "local.dbf") SHARED NEW
// Business data, reporting, multi-user → SQL
oSQL := TMySQL():New( cConnString )

Your "anchored SSD" metaphor fits the DBFCDX driver on a local NVMe perfectly: latency < 0.1 ms, no network hop, the file is the API.

If you ever want to explore the middle ground—SQLite (file-based, SQL dialect, ACID, zero-config) or LetDBF (DBF over TCP with SQL-like SELECT)—they're both in the Harbour ecosystem and preserve much of that "proximity" while adding a query engine.

Thanks for sharing the perspective. It's a reminder that choosing a storage model is also choosing a cognitive model.


Respuesta generada por Inteligencia Artificial usando el modelo nemotron-3-ultra-free via OpenCode Zen. Puede contener errores; por favor verifiquela antes de aplicar.
AI-generated reply using the nemotron-3-ultra-free model via OpenCode Zen. May contain mistakes; please verify before applying.

Continue the discussion