Ragna Ragna is a query builder for projects written in Delphi, compatible with FireDAC and UniDAC components.
We created a channel on Telegram for questions and support:
Installation is done using the boss install command:
boss install ragna
If you choose to install manually, simply add the following folders to your project, in Project > Options > Resource Compiler > Directories and Conditionals > Include file search path
../ragna/src/core
../ragna/src/helpers
../ragna/src/interfaces
../ragna/src/state
../ragna/src/types
You need to use Ragna
uses Ragna;- Open query
begin Country.OpenUp; end;
- Open empty query
begin Country.OpenEmpty; end;
- Where
begin Country .Where(CountryName).Equals('Brazil') .OpenUp; end;
- Or
begin Country .Where(CountryName).Equals('Brazil') .&Or(CountryName).Equals('Canada') .OpenUp; end;
- And
begin Country .Where(CountryName).Equals('Brazil') .&And(CountryCapital).Equals('Brasilia') .OpenUp; end;
- Like
begin Country .Where(CountryName).Like('B') .OpenUp; end;
- Order
begin Country .Order(CountryName) .OpenUp; end;
- To JSON object
var LJson: TJSONObject; begin LJson := Country.OpenUp.ToJSONObject; end;
- To JSON array
var LJson: TJSONArray; begin LJson := Country.OpenUp.ToJSONArray; end;
Ragna is free and open-source middleware licensed under the MIT License.