Site icon Embarcadero RAD Studio, Delphi, & C++Builder Blogs

Easily Use Nonstandard Data Using X-DBData for Delphi

X DBData Components

X-DBData is a VCL and FMX nonvisual component package that helps users bridge between Delphi’s data-aware and non-data-aware components.

There are two paradigms within the Delphi IDE.

FeatureNon-Data-Aware Edit ComponentsData-Aware Edit Components
Data ManipulationManual – using .Text, .Caption, .Value propertiesAutomatic field-linking via Field and DataSource properties
Data RefreshManual – data has to be updated via codeAutomatic update via Dataset Paradigm
Data TypeManual – certain data-types conversion
(e.g., using TEdit to load and save Date type)
Automatic – Data-type is preserved if the correct Data-Aware TEdit is used.
(e.g., using Data-Aware version of TDatePicker)
AdvantagesAllows complete control of the UI via coding.Development time significantly reduced.
Viable low-code solution.
Exponentially reduce the amount of code required for database-transaction processing
DisadvantagesInability to use TDBGrid.
Tedious and time-consuming to code UI to link UI
to database
Require data source (e.g., database) to have TDataSet components available.
Non-Data-Aware vs Data-Aware Edit Componnets

Non-Database Business Solutions

X-DBData solves niche problems where your Delphi application is required to process large amounts of data.

Examples are:

Using data-aware database components can dramatically reduce the amount of code for database-transaction processing.

X-DBData allows Delphi objects, such as TList, TObjectList, and generics to be used as a TDataSet replacement, without requiring a primary key. 

Delphi generics can encapsulate certain kinds of data for which it is difficult to force a primary key, such as hierarchical data (files and folder), time-series data (stocks), and web-based state machine data (Vue, react states).


Getting Started

In the below-mentioned video, you can see it takes less than a minute to install X-DBData.

https://www.youtube.com/watch?v=_BcyQf2fnPE

Step 1. Select Tools > GetIt Package Manager, as seen below

<br>

Step 2. When the GetIt Package Manager Window appears (shown below).
1. type in “x-dbdata”.
2. Click on the Install Button.

Step 3. After installation, go to the Component Palette. Scroll to the bottom, where you should see OnGuard, with all the registered components.

1. Palette with X-DBData components.


QIF Editor Recipe

In this below example, I use X-DBData to quickly read Quicken Interchange Format (QIF), exported from a bank website, or from QuickBooks On-Line.

A sample custom data-aware integration would take ~5 minutes to integrate.

The QIF data structure takes a list of QIF transaction data and, using X-DBData, changes it from a list of QIF data.

[crayon-673fc3b134e71032932638/]

The QIF editor allows a user to edit transactions, create or delete transactions, load from CSV (Excel), and export to CSV (Excel).

QIF Editor

The QIF data is loaded into TTransactionList and into TXDBData:

[crayon-673fc3b134e7a032158602/]

The resulting QIF file saved from QIF Editor is then uploaded to QuickBooks Online or Xero.

Note: I used the full version of X-DBData while developing QIF editor. I have shipped several products (with full-source code) using X-DBData.

The source-code of QIF editor is found at https://github.com/PolywickStudio/X-DBDataRecipe

Exit mobile version